@aopslabs/aops-server 0.2.2 → 0.2.3

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.
Files changed (49) hide show
  1. package/THIRD_PARTY_NOTICES +425 -16
  2. package/THIRD_PARTY_NOTICES.inventory.json +70 -10
  3. package/build/client/_app/immutable/chunks/B88gKiyt.js +1 -0
  4. package/build/client/_app/immutable/entry/{app.a0iGCm6X.js → app.DyrORum_.js} +2 -2
  5. package/build/client/_app/immutable/entry/start.BCM14rdL.js +1 -0
  6. package/build/client/_app/immutable/nodes/{1.BtbjYUHR.js → 1.DM-iOsKD.js} +1 -1
  7. package/build/client/_app/version.json +1 -1
  8. package/build/handler.js +3 -3
  9. package/build/index.js +3 -3
  10. package/build/server/chunks/{1-UJuUicIe.js → 1-CbIMYd7N.js} +2 -2
  11. package/build/server/chunks/{_server.ts-6bdzoHJH.js → _server.ts-5jTLRkY0.js} +17 -6
  12. package/build/server/chunks/{_server.ts-u2UWBqNN.js → _server.ts-6MVYw3sO.js} +1 -1
  13. package/build/server/chunks/{_server.ts-DQzYSH_C.js → _server.ts-B7LBExsI.js} +12 -9
  14. package/build/server/chunks/{_server.ts-o9pJceJP.js → _server.ts-BF5YsxES.js} +1 -1
  15. package/build/server/chunks/{_server.ts-Ua5Ieisy.js → _server.ts-BUI8oOpK.js} +13 -10
  16. package/build/server/chunks/{_server.ts-Bz-Erv-1.js → _server.ts-BWMQcP-R.js} +1 -1
  17. package/build/server/chunks/{_server.ts-CRKd0KAC.js → _server.ts-Bd_TqS-J.js} +13 -10
  18. package/build/server/chunks/{_server.ts-BX4X0tW0.js → _server.ts-BrEAWHDb.js} +1 -1
  19. package/build/server/chunks/{_server.ts-DsTeOL2P.js → _server.ts-C1zRNRcN.js} +1 -1
  20. package/build/server/chunks/{_server.ts-DQWRrk5C.js → _server.ts-CQ436Lhs.js} +1 -1
  21. package/build/server/chunks/{_server.ts-N61POKjl.js → _server.ts-CX96Yo6-.js} +12 -9
  22. package/build/server/chunks/{_server.ts-BkxSxdd0.js → _server.ts-CkYsJYFX.js} +29 -68
  23. package/build/server/chunks/{_server.ts-DaIr3NkR.js → _server.ts-ClhXKSU-.js} +1 -1
  24. package/build/server/chunks/{_server.ts-B9gjXi95.js → _server.ts-D7mxMg8q.js} +1 -1
  25. package/build/server/chunks/{_server.ts-CjzSQgpk.js → _server.ts-DHaqrCbN.js} +11 -8
  26. package/build/server/chunks/{_server.ts-XmKDT59M.js → _server.ts-DbPb54XR.js} +13 -10
  27. package/build/server/chunks/{_server.ts-De9ZrSV0.js → _server.ts-P-bj5Kfv.js} +12 -9
  28. package/build/server/chunks/{_server.ts-AwMeEYiZ.js → _server.ts-p6Wxv_wG.js} +1 -1
  29. package/build/server/chunks/{agent-gateway-runtime-C7Kvvy0H.js → agent-gateway-runtime-DV-xLmJx.js} +39 -4
  30. package/build/server/chunks/commercial-admission-loader-ZGZHRPLe.js +480 -0
  31. package/build/server/chunks/{discovery-BvDEgiqC.js → discovery-DL0RzVks.js} +2 -2
  32. package/build/server/chunks/{error.svelte-B9R6O_Hn.js → error.svelte-BTdVSWca.js} +1 -1
  33. package/build/server/chunks/{handler-DurXhqww.js → handler-VLy1sI9x.js} +262 -2
  34. package/build/server/chunks/{hooks.server-DYGrWbgh.js → hooks.server-Zx-k_ERd.js} +1 -1
  35. package/build/server/chunks/{index.js-BQnOaW3H.js → index.js-CWgll4BT.js} +921 -924
  36. package/build/server/chunks/{manifest.js-CCJDdahY.js → manifest.js-C2lkmNzz.js} +20 -20
  37. package/build/server/chunks/{registry-DO8ob5o1.js → registry-DIreA2IZ.js} +132 -268
  38. package/cockpit/.vite/manifest.json +122 -122
  39. package/cockpit/community.module-inventory.json +30 -30
  40. package/host.config.json +140 -0
  41. package/npm-shrinkwrap.json +5131 -0
  42. package/package.json +8 -2
  43. package/runtime/commercial-integrity-worker.mjs +8 -1
  44. package/runtime-closure.package.json +12 -1
  45. package/build/client/_app/immutable/chunks/BlANKL2r.js +0 -1
  46. package/build/client/_app/immutable/entry/start.Df7u6fQ1.js +0 -1
  47. package/build/server/chunks/admission-snapshot-C2wGfTWE.js +0 -1034
  48. package/build/server/chunks/canonical-text-order-DbXJJnFD.js +0 -5
  49. package/build/server/chunks/commercial-admission-loader-V_vXHdVa.js +0 -2077
@@ -0,0 +1 @@
1
+ import{aD as ve,aE as bt,aA as oe,aF as kt,aB as A,G as U,ag as T}from"./2_TffmqH.js";import{o as Be}from"./B2EkC-sy.js";const V=[];function Ae(e,t=ve){let n=null;const r=new Set;function a(o){if(bt(e,o)&&(e=o,n)){const c=!V.length;for(const l of r)l[1](),V.push(l,e);if(c){for(let l=0;l<V.length;l+=2)V[l][0](V[l+1]);V.length=0}}}function i(o){a(o(e))}function s(o,c=ve){const l=[o,c];return r.add(l),r.size===1&&(n=t(a,i)||ve),o(e),()=>{r.delete(l),r.size===0&&n&&(n(),n=null)}}return{set:a,update:i,subscribe:s}}const Et="1786099489883",L=globalThis.__sveltekit_141pzln?.base??"",St=globalThis.__sveltekit_141pzln?.assets??L??"";new URL("sveltekit-internal://");function Rt(e,t){return e==="/"||t==="ignore"?e:t==="never"?e.endsWith("/")?e.slice(0,-1):e:t==="always"&&!e.endsWith("/")?e+"/":e}function xt(e){return e.split("%25").map(decodeURI).join("%25")}function Lt(e){for(const t in e)e[t]=decodeURIComponent(e[t]);return e}function ye({href:e}){return e.split("#")[0]}const At=/^(\[)?(\.\.\.)?(\w+)(?:=(\w+))?(\])?$/,Ut=/^\/\((?:[^)]+)\)$/;function Tt(e){const t=[];return{pattern:e==="/"||Ut.test(e)?/^\/$/:new RegExp(`^${Pt(e).map(r=>{const a=/^\[\.\.\.(\w+)(?:=(\w+))?\]$/.exec(r);if(a)return t.push({name:a[1],matcher:a[2],optional:!1,rest:!0,chained:!0}),"(?:/([^]*))?";const i=/^\[\[(\w+)(?:=(\w+))?\]\]$/.exec(r);if(i)return t.push({name:i[1],matcher:i[2],optional:!0,rest:!1,chained:!0}),"(?:/([^/]+))?";if(!r)return;const s=r.split(/\[(.+?)\](?!\])/);return"/"+s.map((c,l)=>{if(l%2){if(c.startsWith("x+"))return be(String.fromCharCode(parseInt(c.slice(2),16)));if(c.startsWith("u+"))return be(String.fromCharCode(...c.slice(2).split("-").map(m=>parseInt(m,16))));const u=At.exec(c),[,p,w,d,f]=u;return t.push({name:d,matcher:f,optional:!!p,rest:!!w,chained:w?l===1&&s[0]==="":!1}),w?"([^]*?)":p?"([^/]*)?":"([^/]+?)"}return be(c)}).join("")}).join("")}/?$`),params:t}}function It(e){return e!==""&&!/^\([^)]+\)$/.test(e)}function Pt(e){return e.slice(1).split("/").filter(It)}function Ot(e,t,n){const r={},a=e.slice(1),i=a.filter(o=>o!==void 0);let s=0;for(let o=0;o<t.length;o+=1){const c=t[o];let l=a[o-s];if(c.chained&&c.rest&&s&&(l=a.slice(o-s,o+1).filter(u=>u).join("/"),s=0),l===void 0)if(c.rest)l="";else continue;if(!c.matcher||n[c.matcher](l)){r[c.name]=l;const u=t[o+1],p=a[o+1];u&&!u.rest&&u.optional&&p&&c.chained&&(s=0),!u&&!p&&Object.keys(r).length===i.length&&(s=0);continue}if(c.optional&&c.chained){s++;continue}return}if(!s)return r}function be(e){return e.normalize().replace(/[[\]]/g,"\\$&").replace(/%/g,"%25").replace(/\//g,"%2[Ff]").replace(/\?/g,"%3[Ff]").replace(/#/g,"%23").replace(/[.*+?^${}()|\\]/g,"\\$&")}class Ue{constructor(t,n){this.status=t,typeof n=="string"?this.body={message:n}:n?this.body=n:this.body={message:`Error: ${t}`}}toString(){return JSON.stringify(this.body)}}class Te{constructor(t,n){try{new Headers({location:n})}catch{throw new Error(`Invalid redirect location ${JSON.stringify(n)}: this string contains characters that cannot be used in HTTP headers`)}this.status=t,this.location=n}}class Ie extends Error{constructor(t,n,r){super(r),this.status=t,this.text=n}}function C(){}function $t(...e){let t=5381;for(const n of e)if(typeof n=="string"){let r=n.length;for(;r;)t=t*33^n.charCodeAt(--r)}else if(ArrayBuffer.isView(n)){const r=new Uint8Array(n.buffer,n.byteOffset,n.byteLength);let a=r.length;for(;a;)t=t*33^r[--a]}else throw new TypeError("value must be a string or TypedArray");return(t>>>0).toString(36)}new TextEncoder;function Ct(e){const t=atob(e),n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n}const Nt=window.fetch;window.fetch=(e,t)=>((e instanceof Request?e.method:t?.method||"GET")!=="GET"&&Y.delete(Pe(e)),Nt(e,t));const Y=new Map;function jt(e,t){const n=Pe(e,t),r=document.querySelector(n);if(r?.textContent){r.remove();let{body:a,...i}=JSON.parse(r.textContent);r.getAttribute("data-b64")!==null&&(a=Ct(a));const o=r.getAttribute("data-ttl");return o&&Y.set(n,{body:a,init:i,ttl:1e3*Number(o)}),Promise.resolve(new Response(a,i))}return window.fetch(e,t)}function qt(e,t,n){if(Y.size>0){const r=Pe(e,n),a=Y.get(r);if(a){if(performance.now()<a.ttl&&["default","force-cache","only-if-cached",void 0].includes(n?.cache))return new Response(a.body,a.init);Y.delete(r)}}return window.fetch(t,n)}function Pe(e,t){let r=`script[data-sveltekit-fetched][data-url=${JSON.stringify(e instanceof Request?e.url:e)}]`;if(t?.headers||t?.body){const a=[];t.headers&&a.push([...new Headers(t.headers)].join(",")),t.body&&(typeof t.body=="string"||ArrayBuffer.isView(t.body))&&a.push(t.body),r+=`[data-hash="${$t(...a)}"]`}return r}function Dt({nodes:e,server_loads:t,dictionary:n,matchers:r}){const a=new Set(t);return Object.entries(n).map(([o,[c,l,u]])=>{const{pattern:p,params:w}=Tt(o),d={id:o,exec:f=>{const m=p.exec(f);if(m)return Ot(m,w,r)},errors:[1,...u||[]].map(f=>e[f]),layouts:[0,...l||[]].map(s),leaf:i(c)};return d.errors.length=d.layouts.length=Math.max(d.errors.length,d.layouts.length),d});function i(o){const c=o<0;return c&&(o=~o),[c,e[o]]}function s(o){return o===void 0?o:[a.has(o),e[o]]}}function Qe(e,t=JSON.parse){try{return t(sessionStorage[e])}catch{}}function Fe(e,t,n=JSON.stringify){const r=n(t);try{sessionStorage[e]=r}catch{}}const Ze="sveltekit:snapshot",et="sveltekit:scroll",tt="sveltekit:states",Vt="sveltekit:pageurl",B="sveltekit:history",Q="sveltekit:navigation",q={tap:1,hover:2,viewport:3,eager:4,off:-1,false:-1},nt=new Set(["load","prerender","csr","ssr","trailingSlash","config"]);[...nt];const zt=new Set([...nt]);[...zt];function Mt(e){return e.filter(t=>t!=null)}function re(e,t){return e+"/"+t}function Oe(e){return e instanceof Ue||e instanceof Ie?e.status:500}function Bt(e){return e instanceof Ie?e.text:"Internal Error"}const Ft=new Set(["icon","shortcut icon","apple-touch-icon"]);let W=null;const j=Qe(et)??{},Z=Qe(Ze)??{},N={url:Ye({}),page:Ye({}),navigating:Ae(null),updated:fn()};function $e(e){j[e]=D()}function Kt(e,t){let n=e+1;for(;j[n];)delete j[n],n+=1;for(n=t+1;Z[n];)delete Z[n],n+=1}function ee(e,t=!1){return t?location.replace(e.href):location.href=e.href,new Promise(C)}async function rt(){if("serviceWorker"in navigator){const e=await navigator.serviceWorker.getRegistration(L||"/");e&&await e.update()}}let Ce,Se,se,I,Re,v;const ie=[],ce=[];let S=null;function le(){S?.fork?.then(e=>e?.discard()),S=null,M={element:void 0,href:void 0}}const ae=new Map,at=new Set,Gt=new Set,X=new Set;let _={branch:[],error:null,url:null},ot=!1,ue=!1,Ke=!0,te=!1,J=!1,st=!1,Ne=!1,it,y,R,$;const fe=new Set,Ge=new Map,He=new Map;async function gn(e,t,n){if(globalThis.__sveltekit_141pzln.data){const{q:i={},p:s={},l:o={},f:c={}}=globalThis.__sveltekit_141pzln.data;for(const l in i)i[l];for(const l in o)o[l];for(const l in c)c[l];for(const l in s)s[l]}document.URL!==location.href&&(location.href=location.href),v=e,await e.hooks.init?.(),Ce=Dt(e),I=document.documentElement,Re=t,Se=e.nodes[0],se=e.nodes[1],Se(),se(),y=history.state?.[B],R=history.state?.[Q],y||(y=R=Date.now(),history.replaceState({...history.state,[B]:y,[Q]:R},""));const r=j[y];function a(){r&&(history.scrollRestoration="manual",scrollTo(r.x,r.y))}n?(a(),await sn(Re,n)):(await F({type:"enter",url:gt(v.hash?un(new URL(location.href)):location.href),replace_state:!0}),a()),on()}function Ht(){ie.length=0,Ne=!1}function ct(e){ce.some(t=>t?.snapshot)&&(Z[e]=ce.map(t=>t?.snapshot?.capture()))}function lt(e){Z[e]?.forEach((t,n)=>{ce[n]?.snapshot?.restore(t)})}function We(){$e(y),Fe(et,j),ct(R),Fe(Ze,Z)}async function Wt(e,t,n,r){let a,i;t.invalidateAll&&le(),await F({type:"goto",url:gt(e),keepfocus:t.keepFocus,noscroll:t.noScroll,replace_state:t.replaceState,state:t.state,redirect_count:n,nav_token:r,accept:()=>{if(t.invalidateAll){Ne=!0,a=new Set;for(const[s,o]of Ge)for(const[c,l]of o)l.resource?.reset(),a.add(re(s,c));i=new Set;for(const[s,o]of He)for(const c of o.keys())i.add(re(s,c))}t.invalidate&&t.invalidate.forEach(an)}}),t.invalidateAll&&oe().then(oe).then(()=>{for(const[s,o]of Ge)for(const[c,{resource:l}]of o)a?.has(re(s,c))&&l.start();for(const[s,o]of He)for(const[c,{resource:l}]of o)i?.has(re(s,c))&&l.reconnect()})}async function Jt(e){if(e.id!==S?.id){le();const t={};fe.add(t),S={id:e.id,token:t,promise:ft({...e,preload:t}).then(n=>(fe.delete(t),n.type==="loaded"&&n.state.error&&le(),n)),fork:null}}return S.promise}async function ke(e){const t=(await ge(e,!1))?.route;t&&await Promise.all([...t.layouts,t.leaf].filter(Boolean).map(n=>n[1]()))}async function ut(e,t,n){const r={params:_.params,route:{id:_.route?.id??null},url:new URL(location.href)};if(_={...e.state,nav:r},vt(e.props.page),it=new v.root({target:t,props:{...e.props,stores:N,components:ce},hydrate:n,sync:!1,transformError:void 0}),await Promise.resolve(),n){const a={from:null,to:{...r,scroll:j[y]??D()},willUnload:!1,type:"enter",complete:Promise.resolve()};X.forEach(i=>i(a))}lt(R),ue=!0}async function de({url:e,params:t,branch:n,errors:r,status:a,error:i,route:s,form:o}){let c="never";if(L&&(e.pathname===L||e.pathname===L+"/"))c="always";else for(const f of n)f?.slash!==void 0&&(c=f.slash);e.pathname=Rt(e.pathname,c),e.search=e.search;const l={type:"loaded",state:{url:e,params:t,branch:n,error:i,route:s},props:{constructors:Mt(n).map(f=>f.node.component),page:ze(x)}};o!==void 0&&(l.props.form=o);let u={},p=!x,w=0;for(let f=0;f<Math.max(n.length,_.branch.length);f+=1){const m=n[f],g=_.branch[f];m?.data!==g?.data&&(p=!0),m&&(u={...u,...m.data},p&&(l.props[`data_${w}`]=u),w+=1)}return(!_.url||e.href!==_.url.href||_.error!==i||o!==void 0&&o!==x.form||p)&&(l.props.page={error:i,params:t,route:{id:s?.id??null},state:{},status:a,url:new URL(e),form:o??null,data:p?u:x.data}),l}async function je({loader:e,parent:t,url:n,params:r,route:a,server_data_node:i}){let s=null;const o={dependencies:new Set,params:new Set,parent:!1,route:!1,url:!1,search_params:new Set},c=await e();return{node:c,loader:e,server:i,universal:c.universal?.load?{type:"data",data:s,uses:o}:null,data:s??i?.data??null,slash:c.universal?.trailingSlash??i?.slash}}function Yt(e,t,n){let r=e instanceof Request?e.url:e;const a=new URL(r,n);a.origin===n.origin&&(r=a.href.slice(n.origin.length));const i=ue?qt(r,a.href,t):jt(r,t);return{resolved:a,promise:i}}function Xt(e,t,n,r,a,i){if(Ne)return!0;if(!a)return!1;if(a.parent&&e||a.route&&t||a.url&&n)return!0;for(const s of a.search_params)if(r.has(s))return!0;for(const s of a.params)if(i[s]!==_.params[s])return!0;for(const s of a.dependencies)if(ie.some(o=>o(new URL(s))))return!0;return!1}function qe(e,t){return e?.type==="data"?e:e?.type==="skip"?t??null:null}function Qt(e,t){if(!e)return new Set(t.searchParams.keys());const n=new Set([...e.searchParams.keys(),...t.searchParams.keys()]);for(const r of n){const a=e.searchParams.getAll(r),i=t.searchParams.getAll(r);a.every(s=>i.includes(s))&&i.every(s=>a.includes(s))&&n.delete(r)}return n}function Zt({error:e,url:t,route:n,params:r}){return{type:"loaded",state:{error:e,url:t,route:n,params:r,branch:[]},props:{page:ze(x),constructors:[]}}}async function ft({id:e,invalidating:t,url:n,params:r,route:a,preload:i}){if(S?.id===e)return fe.delete(S.token),S.promise;const{errors:s,layouts:o,leaf:c}=a,l=[...o,c];s.forEach(g=>g?.().catch(C)),l.forEach(g=>g?.[1]().catch(C));const u=_.url?e!==he(_.url):!1,p=_.route?a.id!==_.route.id:!1,w=Qt(_.url,n);let d=!1;const f=l.map(async(g,h)=>{if(!g)return;const b=_.branch[h];return g[1]===b?.loader&&!Xt(d,p,u,w,b.universal?.uses,r)?b:(d=!0,je({loader:g[1],url:n,params:r,route:a,parent:async()=>{const P={};for(let O=0;O<h;O+=1)Object.assign(P,(await f[O])?.data);return P},server_data_node:qe(g[0]?{type:"skip"}:null,g[0]?b?.server:void 0)}))});for(const g of f)g.catch(C);const m=[];for(let g=0;g<l.length;g+=1)if(l[g])try{m.push(await f[g])}catch(h){if(h instanceof Te)return{type:"redirect",location:h.location};if(i&&fe.has(i))return Zt({error:await K(h,{params:r,url:n,route:{id:a.id}}),url:n,params:r,route:a});let b=Oe(h),E;if(h instanceof Ue)E=h.body;else{if(await N.updated.check())return await rt(),await ee(n);E=await K(h,{params:r,url:n,route:{id:a.id}})}const P=await en(g,m,s);return P?de({url:n,params:r,branch:m.slice(0,P.idx).concat(P.node),errors:s,status:b,error:E,route:a}):await ht(n,{id:a.id},E,b)}else m.push(void 0);return de({url:n,params:r,branch:m,errors:s,status:200,error:null,route:a,form:t?void 0:null})}async function en(e,t,n){for(;e--;)if(n[e]){let r=e;for(;!t[r];)r-=1;try{return{idx:r+1,node:{node:await n[e](),loader:n[e],data:{},server:null,universal:null}}}catch{continue}}}async function De({status:e,error:t,url:n,route:r}){const a={};let i=null;try{const s=await je({loader:Se,url:n,params:a,route:r,parent:()=>Promise.resolve({}),server_data_node:qe(i)}),o={node:await se(),loader:se,universal:null,server:null,data:null};return de({url:n,params:a,branch:[s,o],status:e,error:t,errors:[],route:null})}catch(s){if(s instanceof Te){await Wt(new URL(s.location,location.href),{},0);return}const o=await v.get_error_template(),c=await K(s,{url:n,params:a,route:r}),l=String(c?.message??"").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),u=o({status:e,message:l}),p=new DOMParser().parseFromString(u,"text/html");throw document.documentElement.replaceChild(document.adoptNode(p.head),document.head),document.documentElement.replaceChild(document.adoptNode(p.body),document.body),s}}async function tn(e){const t=e.href;if(ae.has(t))return ae.get(t);let n;try{const r=(async()=>{let a=await v.hooks.reroute({url:new URL(e),fetch:async(i,s)=>Yt(i,s,e).promise})??e;if(typeof a=="string"){const i=new URL(e);v.hash?i.hash=a:i.pathname=a,a=i}return a})();ae.set(t,r),n=await r}catch{ae.delete(t);return}return n}async function ge(e,t){if(e&&!me(e,L,v.hash)){const n=await tn(e);if(!n)return;const r=nn(n);for(const a of Ce){const i=a.exec(r);if(i)return{id:he(e),invalidating:t,route:a,params:Lt(i),url:e}}}}function nn(e){return xt(v.hash?e.hash.replace(/^#/,"").replace(/[?#].+/,""):e.pathname.slice(L.length))||"/"}function he(e){return(v.hash?e.hash.replace(/^#/,""):e.pathname)+e.search}function dt({url:e,type:t,intent:n,delta:r,event:a,scroll:i}){let s=!1;const o=Ve(_,n,e,t,i??null);r!==void 0&&(o.navigation.delta=r),a!==void 0&&(o.navigation.event=a);const c={...o.navigation,cancel:()=>{s=!0,o.reject(new Error("navigation cancelled"))}};return te||at.forEach(l=>l(c)),s?null:o}async function F({type:e,url:t,popped:n,keepfocus:r,noscroll:a,replace_state:i,state:s={},redirect_count:o=0,nav_token:c={},accept:l=C,block:u=C,event:p}){const w=$;$=c;const d=await ge(t,!1),f=e==="enter"?Ve(_,d,t,e):dt({url:t,type:e,delta:n?.delta,intent:d,scroll:n?.scroll,event:p});if(!f){u(),$===c&&($=w);return}const m=y,g=R;l(),te=!0,ue&&f.navigation.type!=="enter"&&N.navigating.set(ne.current=f.navigation);let h=d&&await ft(d);if(!h){if(me(t,L,v.hash))return await ee(t,i);h=await ht(t,{id:null},await K(new Ie(404,"Not Found",`Not found: ${t.pathname}`),{url:t,params:{},route:{id:null}}),404,i)}if(t=d?.url||t,$!==c){f.reject(new Error("navigation aborted"));return}if(!h)return;if(h.type==="redirect"){if(o<20){await F({type:e,url:new URL(h.location,t),popped:n,keepfocus:r,noscroll:a,replace_state:i,state:s,redirect_count:o+1,nav_token:c}),f.fulfil(void 0);return}if(h=await De({status:500,error:await K(new Error("Redirect loop"),{url:t,params:{},route:{id:null}}),url:t,route:{id:null}}),!h)return}else if(h.props.page.status>=400&&await N.updated.check())return await rt(),await ee(t,i);if(Ht(),$e(m),ct(g),h.props.page.url.pathname!==t.pathname&&(t.pathname=h.props.page.url.pathname),s=n?n.state:s,!n){const k=i?0:1,G={[B]:y+=k,[Q]:R+=k,[tt]:s};(i?history.replaceState:history.pushState).call(history,G,"",t),i||Kt(y,R)}const b=d&&S?.id===d.id?S.fork:null;S?.fork&&!b?le():(S=null,M={element:void 0,href:void 0}),h.props.page.state=s;let E;if(ue){const k=(await Promise.all(Array.from(Gt,H=>H(f.navigation)))).filter(H=>typeof H=="function");if(k.length>0){let H=function(){k.forEach(we=>{X.delete(we)})};k.push(H),k.forEach(we=>{X.add(we)})}const G=f.navigation.to;_={...h.state,nav:{params:G.params,route:G.route,url:G.url}},h.props.page&&(h.props.page.url=t),!r&&document.activeElement instanceof HTMLElement&&document.activeElement!==document.body&&document.activeElement.blur();const _e=b&&await b;_e?E=_e.commit():(W=null,it.$set(h.props),W&&Object.assign(h.props.page,W),vt(h.props.page),E=kt?.()),st=!0}else await ut(h,Re,!1);const{activeElement:P}=document;if(await E,await oe(),await oe(),$!==c){f.reject(new Error("navigation aborted"));return}h.props.page&&W&&Object.assign(h.props.page,W);let O=null;if(Ke){const k=n?n.scroll:a?D():null;k?scrollTo(k.x,k.y):(O=t.hash&&document.getElementById(pt(t)))?O.scrollIntoView():scrollTo(0,0)}const yt=document.activeElement!==P&&document.activeElement!==document.body;!r&&!yt&&ln(t,!O),Ke=!0,te=!1,f.fulfil(void 0),f.navigation.to&&(f.navigation.to.scroll=D()),X.forEach(k=>k(f.navigation)),e==="popstate"&&lt(R),N.navigating.set(ne.current=null)}async function ht(e,t,n,r,a){return e.origin===Me&&e.pathname===location.pathname&&!ot?await De({status:r,error:n,url:e,route:t}):await ee(e,a)}let M={element:void 0,href:void 0};function rn(){let e,t;I.addEventListener("mousemove",s=>{const o=s.target;clearTimeout(e),e=setTimeout(()=>{a(o,q.hover)},20)});function n(s){s.defaultPrevented||a(s.composedPath()[0],q.tap)}I.addEventListener("mousedown",n),I.addEventListener("touchstart",n,{passive:!0});const r=new IntersectionObserver(s=>{for(const o of s)o.isIntersecting&&(ke(new URL(o.target.href)),r.unobserve(o.target))},{threshold:0});async function a(s,o){const c=_t(s,I),l=c===M.element&&c?.href===M.href&&o>=t;if(!c||l)return;const{url:u,external:p,download:w}=Le(c,L,v.hash);if(p||w)return;const d=pe(c),f=u&&he(_.url)===he(u);if(!(d.reload||f))if(o<=d.preload_data){M={element:c,href:c.href},t=q.tap;const m=await ge(u,!1);if(!m)return;Jt(m)}else o<=d.preload_code&&(M={element:c,href:c.href},t=o,ke(u))}function i(){r.disconnect();for(const s of I.querySelectorAll("a")){const{url:o,external:c,download:l}=Le(s,L,v.hash);if(c||l)continue;const u=pe(s);u.reload||(u.preload_code===q.viewport&&r.observe(s),u.preload_code===q.eager&&ke(o))}}X.add(i),i()}function K(e,t){if(e instanceof Ue)return e.body;const n=Oe(e),r=Bt(e);return v.hooks.handleError({error:e,event:t,status:n,message:r})??{message:r}}function an(e){if(typeof e=="function")ie.push(e);else{const{href:t}=new URL(e,location.href);ie.push(n=>n.href===t)}}function on(){history.scrollRestoration="manual",addEventListener("beforeunload",t=>{let n=!1;if(We(),!te){const r=Ve(_,void 0,null,"leave"),a={...r.navigation,cancel:()=>{n=!0,r.reject(new Error("navigation cancelled"))}};at.forEach(i=>i(a))}n?(t.preventDefault(),t.returnValue=""):history.scrollRestoration="auto"}),addEventListener("visibilitychange",()=>{document.visibilityState==="hidden"&&We()}),navigator.connection?.saveData||rn(),I.addEventListener("click",async t=>{if(t.button||t.which!==1||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.defaultPrevented)return;const n=_t(t.composedPath()[0],I);if(!n)return;const{url:r,external:a,target:i,download:s}=Le(n,L,v.hash);if(!r)return;if(i==="_parent"||i==="_top"){if(window.parent!==window)return}else if(i&&i!=="_self")return;const o=pe(n);if(!(n instanceof SVGAElement)&&r.protocol!==location.protocol&&!(r.protocol==="https:"||r.protocol==="http:")||s)return;const[l,u]=(v.hash?r.hash.replace(/^#/,""):r.href).split("#"),p=l===ye(location);if(a||o.reload&&(!p||!u)){dt({url:r,type:"link",event:t})?te=!0:t.preventDefault();return}if(u!==void 0&&p){const[,w]=_.url.href.split("#");if(w===u){if(t.preventDefault(),u===""||u==="top"&&n.ownerDocument.getElementById("top")===null)scrollTo({top:0});else{const d=n.ownerDocument.getElementById(decodeURIComponent(u));d&&(d.scrollIntoView(),d.focus())}return}if(J=!0,$e(y),e(r),!o.replace_state)return;J=!1}t.preventDefault(),await new Promise(w=>{requestAnimationFrame(()=>{setTimeout(w,0)}),setTimeout(w,100)}),await F({type:"link",url:r,keepfocus:o.keepfocus,noscroll:o.noscroll,replace_state:o.replace_state??r.href===location.href,event:t})}),I.addEventListener("submit",t=>{if(t.defaultPrevented)return;const n=HTMLFormElement.prototype.cloneNode.call(t.target),r=t.submitter;if((r?.formTarget||n.target)==="_blank"||(r?.formMethod||n.method)!=="get")return;const s=new URL(r?.hasAttribute("formaction")&&r?.formAction||n.action);if(me(s,L,!1))return;const o=t.target,c=pe(o);if(c.reload)return;t.preventDefault(),t.stopPropagation();const l=new FormData(o,r);s.search=new URLSearchParams(l).toString(),F({type:"form",url:s,keepfocus:c.keepfocus,noscroll:c.noscroll,replace_state:c.replace_state??s.href===location.href,event:t})}),addEventListener("popstate",async t=>{if(!xe){if(t.state?.[B]){const n=t.state[B];if($={},n===y)return;const r=j[n],a=t.state[tt]??{},i=new URL(t.state[Vt]??location.href),s=t.state[Q],o=_.url?ye(location)===ye(_.url):!1;if(s===R&&(st||o)){a!==x.state&&(x.state=a),e(i),j[y]=D(),r&&scrollTo(r.x,r.y),y=n;return}const l=n-y;await F({type:"popstate",url:i,popped:{state:a,scroll:r,delta:l},accept:()=>{y=n,R=s},block:()=>{history.go(-l)},nav_token:$,event:t})}else if(!J){const n=new URL(location.href);e(n),v.hash&&location.reload()}}}),addEventListener("hashchange",()=>{J&&(J=!1,history.replaceState({...history.state,[B]:++y,[Q]:R},"",location.href))});for(const t of document.querySelectorAll("link"))Ft.has(t.rel)&&(t.href=t.href);addEventListener("pageshow",t=>{t.persisted&&N.navigating.set(ne.current=null)});function e(t){_.url=x.url=t,N.page.set(ze(x)),N.page.notify()}}async function sn(e,{status:t=200,error:n,node_ids:r,params:a,route:i,server_route:s,data:o,form:c}){ot=!0;const l=new URL(location.href);let u;({params:a={},route:i={id:null}}=await ge(l,!1)||{}),u=Ce.find(({id:d})=>d===i.id);let p,w=!0;try{const d=r.map(async(m,g)=>{const h=o[g];return h?.uses&&(h.uses=cn(h.uses)),je({loader:v.nodes[m],url:l,params:a,route:i,parent:async()=>{const b={};for(let E=0;E<g;E+=1)Object.assign(b,(await d[E]).data);return b},server_data_node:qe(h)})}),f=await Promise.all(d);if(u){const m=u.layouts;for(let g=0;g<m.length;g++)m[g]||f.splice(g,0,void 0)}p=await de({url:l,params:a,branch:f,status:t,error:n,errors:u?.errors,form:c,route:u??null})}catch(d){if(d instanceof Te)return await ee(new URL(d.location,location.href));p=await De({status:Oe(d),error:await K(d,{url:l,params:a,route:i}),url:l,route:i}),e.textContent="",w=!1}p&&(p.props.page&&(p.props.page.state={}),await ut(p,e,w))}function cn(e){return{dependencies:new Set(e?.dependencies??[]),params:new Set(e?.params??[]),parent:!!e?.parent,route:!!e?.route,url:!!e?.url,search_params:new Set(e?.search_params??[])}}let xe=!1;function ln(e,t=!0){const n=document.querySelector("[autofocus]");if(n)n.focus();else{const r=pt(e);if(r&&document.getElementById(r)){const{x:i,y:s}=D();setTimeout(()=>{const o=history.state;xe=!0,location.replace(new URL(`#${r}`,location.href)),history.replaceState(o,"",e),t&&scrollTo(i,s),xe=!1})}else{const i=document.body,s=i.getAttribute("tabindex");i.tabIndex=-1,i.focus({preventScroll:!0,focusVisible:!1}),s!==null?i.setAttribute("tabindex",s):i.removeAttribute("tabindex")}const a=getSelection();if(a&&a.type!=="None"){const i=[];for(let s=0;s<a.rangeCount;s+=1)i.push(a.getRangeAt(s));setTimeout(()=>{if(a.rangeCount===i.length){for(let s=0;s<a.rangeCount;s+=1){const o=i[s],c=a.getRangeAt(s);if(o.commonAncestorContainer!==c.commonAncestorContainer||o.startContainer!==c.startContainer||o.endContainer!==c.endContainer||o.startOffset!==c.startOffset||o.endOffset!==c.endOffset)return}a.removeAllRanges()}})}}}function Ve(e,t,n,r,a=null){let i,s;const o=new Promise((l,u)=>{i=l,s=u});return o.catch(C),{navigation:{from:{params:e.params,route:{id:e.route?.id??null},url:e.url,scroll:D()},to:n&&{params:t?.params??null,route:{id:t?.route?.id??null},url:n,scroll:a},willUnload:!t,type:r,complete:o},fulfil:i,reject:s}}function ze(e){return{data:e.data,error:e.error,form:e.form,params:e.params,route:e.route,state:e.state,status:e.status,url:e.url}}function un(e){const t=new URL(e);return t.hash=decodeURIComponent(e.hash),t}function pt(e){let t;if(v.hash){const[,,n]=e.hash.split("#",3);t=n??""}else t=e.hash.slice(1);return decodeURIComponent(t)}const Me=location.origin;function gt(e){if(e instanceof URL)return e;let t=document.baseURI;if(!t){const n=document.getElementsByTagName("base");t=n.length?n[0].href:document.URL}return new URL(e,t)}function D(){return{x:pageXOffset,y:pageYOffset}}function z(e,t){return e.getAttribute(`data-sveltekit-${t}`)}const Je={...q,"":q.hover};function mt(e){let t=e.assignedSlot??e.parentNode;return t?.nodeType===11&&(t=t.host),t}function _t(e,t){for(;e&&e!==t;){if(e.nodeName.toUpperCase()==="A"&&e.hasAttribute("href"))return e;e=mt(e)}}function Le(e,t,n){let r;try{if(r=new URL(e instanceof SVGAElement?e.href.baseVal:e.href,document.baseURI),n&&r.hash.match(/^#[^/]/)){const o=location.hash.split("#")[1]||"/";r.hash=`#${o}${r.hash}`}}catch{}const a=e instanceof SVGAElement?e.target.baseVal:e.target,i=!r||!!a||me(r,t,n)||(e.getAttribute("rel")||"").split(/\s+/).includes("external"),s=r?.origin===Me&&e.hasAttribute("download");return{url:r,external:i,target:a,download:s}}function pe(e){let t=null,n=null,r=null,a=null,i=null,s=null,o=e;for(;o&&o!==document.documentElement;)r===null&&(r=z(o,"preload-code")),a===null&&(a=z(o,"preload-data")),t===null&&(t=z(o,"keepfocus")),n===null&&(n=z(o,"noscroll")),i===null&&(i=z(o,"reload")),s===null&&(s=z(o,"replacestate")),o=mt(o);function c(l){switch(l){case"":case"true":return!0;case"off":case"false":return!1;default:return}}return{preload_code:Je[r??"off"],preload_data:Je[a??"off"],keepfocus:c(t),noscroll:c(n),reload:c(i),replace_state:c(s)}}function Ye(e){const t=Ae(e);let n=!0;function r(){n=!0,t.update(s=>s)}function a(s){n=!1,t.set(s)}function i(s){let o;return t.subscribe(c=>{(o===void 0||n&&c!==o)&&s(o=c)})}return{notify:r,set:a,subscribe:i}}const wt={v:C};function fn(){const{set:e,subscribe:t}=Ae(!1);let n;async function r(){clearTimeout(n);try{const a=await fetch(`${St}/_app/version.json`,{headers:{pragma:"no-cache","cache-control":"no-cache"}});if(!a.ok)return!1;const s=(await a.json()).version!==Et;return s&&(e(!0),wt.v(),clearTimeout(n)),s}catch{return!1}}return{subscribe:t,check:r}}function me(e,t,n){return e.origin!==Me||!e.pathname.startsWith(t)?!0:n?e.pathname!==location.pathname:!1}function mn(e){}let x,ne,Ee;const dn=Be.toString().includes("$$")||/function \w+\(\) \{\}/.test(Be.toString()),Xe="a:";dn?(x={data:{},form:null,error:null,params:{},route:{id:null},state:{},status:-1,url:new URL(Xe)},ne={current:null},Ee={current:!1}):(x=new class{#e=A({});get data(){return U(this.#e)}set data(t){T(this.#e,t)}#t=A(null);get form(){return U(this.#t)}set form(t){T(this.#t,t)}#n=A(null);get error(){return U(this.#n)}set error(t){T(this.#n,t)}#r=A({});get params(){return U(this.#r)}set params(t){T(this.#r,t)}#a=A({id:null});get route(){return U(this.#a)}set route(t){T(this.#a,t)}#o=A({});get state(){return U(this.#o)}set state(t){T(this.#o,t)}#s=A(-1);get status(){return U(this.#s)}set status(t){T(this.#s,t)}#i=A(new URL(Xe));get url(){return U(this.#i)}set url(t){T(this.#i,t)}},ne=new class{#e=A(null);get current(){return U(this.#e)}set current(t){T(this.#e,t)}},Ee=new class{#e=A(!1);get current(){return U(this.#e)}set current(t){T(this.#e,t)}},wt.v=()=>Ee.current=!0);function vt(e){Object.assign(x,e)}export{gn as a,mn as l,x as p,N as s};
@@ -1,2 +1,2 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["../nodes/0.BYBfjxZ5.js","../chunks/rqnVXeyB.js","../chunks/2_TffmqH.js","../chunks/3DOfIKW0.js","../nodes/1.BtbjYUHR.js","../chunks/CMkIcmi1.js","../chunks/BlANKL2r.js","../chunks/B2EkC-sy.js"])))=>i.map(i=>d[i]);
2
- import{ag as R,ah as G,G as h,ai as ie,a2 as oe,aj as ce,h as T,A as V,f as z,E as F,ak as H,Z,C as W,a8 as I,e as J,a5 as ue,i as fe,al as le,H as de,j as K,w as Q,am as _e,an as X,ao as ve,ap as he,aq as me,ar as ge,as as ye,at as be,au as Ee,av as Pe,aw as q,ax as we,ay as Se,k as Re,az as Oe,u as Ae,aA as Te,g as O,q as Ie,l as xe,aB as L,n as Le,o as je,t as ke,aC as j}from"../chunks/2_TffmqH.js";import{h as Ce,m as De,u as Ne,s as Be}from"../chunks/CMkIcmi1.js";import{a as S,f as $,c as k,t as pe}from"../chunks/rqnVXeyB.js";import{o as Me}from"../chunks/B2EkC-sy.js";import{B as ee}from"../chunks/3DOfIKW0.js";const Ye="modulepreload",qe=function(t,e){return new URL(t,e).href},U={},M=function(e,s,i){let c=Promise.resolve();if(s&&s.length>0){let d=function(o){return Promise.all(o.map(v=>Promise.resolve(v).then(E=>({status:"fulfilled",value:E}),E=>({status:"rejected",reason:E}))))};const a=document.getElementsByTagName("link"),n=document.querySelector("meta[property=csp-nonce]"),u=n?.nonce||n?.getAttribute("nonce");c=d(s.map(o=>{if(o=qe(o,i),o in U)return;U[o]=!0;const v=o.endsWith(".css"),E=v?'[rel="stylesheet"]':"";if(i)for(let y=a.length-1;y>=0;y--){const f=a[y];if(f.href===o&&(!v||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${o}"]${E}`))return;const _=document.createElement("link");if(_.rel=v?"stylesheet":Ye,v||(_.as="script"),_.crossOrigin="",_.href=o,u&&_.setAttribute("nonce",u),document.head.appendChild(_),v)return new Promise((y,f)=>{_.addEventListener("load",y),_.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${o}`)))})}))}function r(a){const n=new Event("vite:preloadError",{cancelable:!0});if(n.payload=a,window.dispatchEvent(n),!n.defaultPrevented)throw a}return c.then(a=>{for(const n of a||[])n.status==="rejected"&&r(n.reason);return e().catch(r)})},$e={};let A=!1;function Ue(t){var e=A;try{return A=!1,[t(),A]}finally{A=e}}function Ge(t){return class extends Ve{constructor(e){super({component:t,...e})}}}class Ve{#t;#e;constructor(e){var s=new Map,i=(r,a)=>{var n=ce(a,!1,!1);return s.set(r,n),n};const c=new Proxy({...e.props||{},$$events:{}},{get(r,a){return h(s.get(a)??i(a,Reflect.get(r,a)))},has(r,a){return a===G?!0:(h(s.get(a)??i(a,Reflect.get(r,a))),Reflect.has(r,a))},set(r,a,n){return R(s.get(a)??i(a,n),n),Reflect.set(r,a,n)}});this.#e=(e.hydrate?Ce:De)(e.component,{target:e.target,anchor:e.anchor,props:c,context:e.context,intro:e.intro??!1,recover:e.recover,transformError:e.transformError}),(!e?.props?.$$host||e.sync===!1)&&ie(),this.#t=c.$$events;for(const r of Object.keys(this.#e))r==="$set"||r==="$destroy"||r==="$on"||oe(this,r,{get(){return this.#e[r]},set(a){this.#e[r]=a},enumerable:!0});this.#e.$set=r=>{Object.assign(c,r)},this.#e.$destroy=()=>{Ne(this.#e)}}$set(e){this.#e.$set(e)}$on(e,s){this.#t[e]=this.#t[e]||[];const i=(...c)=>s.call(this,...c);return this.#t[e].push(i),()=>{this.#t[e]=this.#t[e].filter(c=>c!==i)}}$destroy(){this.#e.$destroy()}}function C(t,e,s=!1){var i;T&&(i=J,V());var c=new ee(t),r=s?F:0;function a(n,u){if(T){var d=H(i);if(n!==parseInt(d.substring(1))){var o=Z();W(o),c.anchor=o,I(!1),c.ensure(n,u),I(!0);return}}c.ensure(n,u)}z(()=>{var n=!1;e((u,d=0)=>{n=!0,a(d,u)}),n||a(-1,null)},r)}function D(t,e,s){var i;T&&(i=J,V());var c=new ee(t);z(()=>{var r=e()??null;if(T){var a=H(i),n=a===ue,u=r!==null;if(n!==u){var d=Z();W(d),c.anchor=d,I(!1),c.ensure(r,r&&(o=>s(o,r))),I(!0);return}}c.ensure(r,r&&(o=>s(o,r)))},F)}function N(t,e){return t===e||t?.[X]===e}function B(t={},e,s,i){var c=fe.r,r=Q;return le(()=>{var a,n;return de(()=>{a=n,n=[],K(()=>{N(s(...n),t)||(e(t,...n),a&&N(s(...a),t)&&e(null,...a))})}),()=>{let u=r;for(;u!==c&&u.parent!==null&&u.parent.f&_e;)u=u.parent;const d=()=>{n&&N(s(...n),t)&&e(null,...n)},o=u.teardown;u.teardown=()=>{d(),o?.()}}}),t}function p(t,e,s,i){var c=!0,r=(s&Ee)!==0,a=(s&Se)!==0,n=i,u=!0,d=void 0,o=()=>a&&c?(d??=q(i),h(d)):(u&&(u=!1,n=a?K(i):i),n);let v;if(r){var E=X in t||G in t;v=ve(t,e)?.set??(E&&e in t?l=>t[e]=l:void 0)}var _,y=!1;r?[_,y]=Ue(()=>t[e]):_=t[e],_===void 0&&i!==void 0&&(_=o(),v&&(he(),v(_)));var f;if(f=()=>{var l=t[e];return l===void 0?o():(u=!0,l)},(s&me)===0)return f;if(v){var P=t.$$legacy;return(function(l,b){return arguments.length>0?((!b||P||y)&&v(b?f():l),l):f()})}var m=!1,g=((s&Pe)!==0?q:we)(()=>(m=!1,f()));r&&h(g);var w=Q;return(function(l,b){if(arguments.length>0){const x=b?h(g):r?ge(l):l;return R(g,x),m=!0,n!==void 0&&(n=x),l}return ye&&m||(w.f&be)!==0?g.v:h(g)})}var ze=$('<div id="svelte-announcer" aria-live="assertive" aria-atomic="true" style="position: absolute; left: 0; top: 0; clip: rect(0 0 0 0); clip-path: inset(50%); overflow: hidden; white-space: nowrap; width: 1px; height: 1px"><!></div>'),Fe=$("<!> <!>",1);function He(t,e){Re(e,!0);let s=p(e,"components",23,()=>[]),i=p(e,"data_0",3,null),c=p(e,"data_1",3,null);Oe(()=>e.stores.page.set(e.page)),Ae(()=>{e.stores,e.page,e.constructors,s(),e.form,i(),c(),e.stores.page.notify()});let r=L(!1),a=L(!1),n=L(null);Me(()=>{const f=e.stores.page.subscribe(()=>{h(r)&&(R(a,!0),Te().then(()=>{R(n,document.title||"untitled page",!0)}))});return R(r,!0),f});const u=j(()=>e.constructors[1]);var d=Fe(),o=O(d);{var v=f=>{const P=j(()=>e.constructors[0]);var m=k(),g=O(m);D(g,()=>h(P),(w,l)=>{B(l(w,{get data(){return i()},get form(){return e.form},get params(){return e.page.params},children:(b,x)=>{var Y=k(),re=O(Y);D(re,()=>h(u),(ae,ne)=>{B(ne(ae,{get data(){return c()},get form(){return e.form},get params(){return e.page.params}}),se=>s()[1]=se,()=>s()?.[1])}),S(b,Y)},$$slots:{default:!0}}),b=>s()[0]=b,()=>s()?.[0])}),S(f,m)},E=f=>{const P=j(()=>e.constructors[0]);var m=k(),g=O(m);D(g,()=>h(P),(w,l)=>{B(l(w,{get data(){return i()},get form(){return e.form},get params(){return e.page.params}}),b=>s()[0]=b,()=>s()?.[0])}),S(f,m)};C(o,f=>{e.constructors[1]?f(v):f(E,-1)})}var _=Ie(o,2);{var y=f=>{var P=ze(),m=Le(P);{var g=w=>{var l=pe();ke(()=>Be(l,h(n))),S(w,l)};C(m,w=>{h(a)&&w(g)})}je(P),S(f,P)};C(_,f=>{h(r)&&f(y)})}S(t,d),xe()}const et=Ge(He),tt=[()=>M(()=>import("../nodes/0.BYBfjxZ5.js"),__vite__mapDeps([0,1,2,3]),import.meta.url),()=>M(()=>import("../nodes/1.BtbjYUHR.js"),__vite__mapDeps([4,1,2,5,6,7]),import.meta.url)],rt=[],at={},te={handleError:(({error:t})=>{console.error(t)}),reroute:(()=>{}),transport:{}},Ze=Object.fromEntries(Object.entries(te.transport).map(([t,e])=>[t,e.decode])),nt=Object.fromEntries(Object.entries(te.transport).map(([t,e])=>[t,e.encode])),st=!1,it=(t,e)=>Ze[t](e),ot=()=>M(()=>import("../chunks/wbPk3Yxo.js"),[],import.meta.url).then(t=>t.default);export{it as decode,Ze as decoders,at as dictionary,nt as encoders,ot as get_error_template,st as hash,te as hooks,$e as matchers,tt as nodes,et as root,rt as server_loads};
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["../nodes/0.BYBfjxZ5.js","../chunks/rqnVXeyB.js","../chunks/2_TffmqH.js","../chunks/3DOfIKW0.js","../nodes/1.DM-iOsKD.js","../chunks/CMkIcmi1.js","../chunks/B88gKiyt.js","../chunks/B2EkC-sy.js"])))=>i.map(i=>d[i]);
2
+ import{ag as R,ah as G,G as h,ai as ie,a2 as oe,aj as ce,h as T,A as V,f as z,E as F,ak as H,Z,C as W,a8 as I,e as J,a5 as ue,i as fe,al as le,H as de,j as K,w as Q,am as _e,an as X,ao as ve,ap as he,aq as me,ar as ge,as as ye,at as be,au as Ee,av as Pe,aw as q,ax as we,ay as Se,k as Re,az as Oe,u as Ae,aA as Te,g as O,q as Ie,l as xe,aB as L,n as Le,o as je,t as ke,aC as j}from"../chunks/2_TffmqH.js";import{h as Ce,m as De,u as Ne,s as Be}from"../chunks/CMkIcmi1.js";import{a as S,f as $,c as k,t as pe}from"../chunks/rqnVXeyB.js";import{o as Me}from"../chunks/B2EkC-sy.js";import{B as ee}from"../chunks/3DOfIKW0.js";const Ye="modulepreload",qe=function(t,e){return new URL(t,e).href},U={},M=function(e,s,i){let c=Promise.resolve();if(s&&s.length>0){let d=function(o){return Promise.all(o.map(v=>Promise.resolve(v).then(E=>({status:"fulfilled",value:E}),E=>({status:"rejected",reason:E}))))};const a=document.getElementsByTagName("link"),n=document.querySelector("meta[property=csp-nonce]"),u=n?.nonce||n?.getAttribute("nonce");c=d(s.map(o=>{if(o=qe(o,i),o in U)return;U[o]=!0;const v=o.endsWith(".css"),E=v?'[rel="stylesheet"]':"";if(i)for(let y=a.length-1;y>=0;y--){const f=a[y];if(f.href===o&&(!v||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${o}"]${E}`))return;const _=document.createElement("link");if(_.rel=v?"stylesheet":Ye,v||(_.as="script"),_.crossOrigin="",_.href=o,u&&_.setAttribute("nonce",u),document.head.appendChild(_),v)return new Promise((y,f)=>{_.addEventListener("load",y),_.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${o}`)))})}))}function r(a){const n=new Event("vite:preloadError",{cancelable:!0});if(n.payload=a,window.dispatchEvent(n),!n.defaultPrevented)throw a}return c.then(a=>{for(const n of a||[])n.status==="rejected"&&r(n.reason);return e().catch(r)})},$e={};let A=!1;function Ue(t){var e=A;try{return A=!1,[t(),A]}finally{A=e}}function Ge(t){return class extends Ve{constructor(e){super({component:t,...e})}}}class Ve{#t;#e;constructor(e){var s=new Map,i=(r,a)=>{var n=ce(a,!1,!1);return s.set(r,n),n};const c=new Proxy({...e.props||{},$$events:{}},{get(r,a){return h(s.get(a)??i(a,Reflect.get(r,a)))},has(r,a){return a===G?!0:(h(s.get(a)??i(a,Reflect.get(r,a))),Reflect.has(r,a))},set(r,a,n){return R(s.get(a)??i(a,n),n),Reflect.set(r,a,n)}});this.#e=(e.hydrate?Ce:De)(e.component,{target:e.target,anchor:e.anchor,props:c,context:e.context,intro:e.intro??!1,recover:e.recover,transformError:e.transformError}),(!e?.props?.$$host||e.sync===!1)&&ie(),this.#t=c.$$events;for(const r of Object.keys(this.#e))r==="$set"||r==="$destroy"||r==="$on"||oe(this,r,{get(){return this.#e[r]},set(a){this.#e[r]=a},enumerable:!0});this.#e.$set=r=>{Object.assign(c,r)},this.#e.$destroy=()=>{Ne(this.#e)}}$set(e){this.#e.$set(e)}$on(e,s){this.#t[e]=this.#t[e]||[];const i=(...c)=>s.call(this,...c);return this.#t[e].push(i),()=>{this.#t[e]=this.#t[e].filter(c=>c!==i)}}$destroy(){this.#e.$destroy()}}function C(t,e,s=!1){var i;T&&(i=J,V());var c=new ee(t),r=s?F:0;function a(n,u){if(T){var d=H(i);if(n!==parseInt(d.substring(1))){var o=Z();W(o),c.anchor=o,I(!1),c.ensure(n,u),I(!0);return}}c.ensure(n,u)}z(()=>{var n=!1;e((u,d=0)=>{n=!0,a(d,u)}),n||a(-1,null)},r)}function D(t,e,s){var i;T&&(i=J,V());var c=new ee(t);z(()=>{var r=e()??null;if(T){var a=H(i),n=a===ue,u=r!==null;if(n!==u){var d=Z();W(d),c.anchor=d,I(!1),c.ensure(r,r&&(o=>s(o,r))),I(!0);return}}c.ensure(r,r&&(o=>s(o,r)))},F)}function N(t,e){return t===e||t?.[X]===e}function B(t={},e,s,i){var c=fe.r,r=Q;return le(()=>{var a,n;return de(()=>{a=n,n=[],K(()=>{N(s(...n),t)||(e(t,...n),a&&N(s(...a),t)&&e(null,...a))})}),()=>{let u=r;for(;u!==c&&u.parent!==null&&u.parent.f&_e;)u=u.parent;const d=()=>{n&&N(s(...n),t)&&e(null,...n)},o=u.teardown;u.teardown=()=>{d(),o?.()}}}),t}function p(t,e,s,i){var c=!0,r=(s&Ee)!==0,a=(s&Se)!==0,n=i,u=!0,d=void 0,o=()=>a&&c?(d??=q(i),h(d)):(u&&(u=!1,n=a?K(i):i),n);let v;if(r){var E=X in t||G in t;v=ve(t,e)?.set??(E&&e in t?l=>t[e]=l:void 0)}var _,y=!1;r?[_,y]=Ue(()=>t[e]):_=t[e],_===void 0&&i!==void 0&&(_=o(),v&&(he(),v(_)));var f;if(f=()=>{var l=t[e];return l===void 0?o():(u=!0,l)},(s&me)===0)return f;if(v){var P=t.$$legacy;return(function(l,b){return arguments.length>0?((!b||P||y)&&v(b?f():l),l):f()})}var m=!1,g=((s&Pe)!==0?q:we)(()=>(m=!1,f()));r&&h(g);var w=Q;return(function(l,b){if(arguments.length>0){const x=b?h(g):r?ge(l):l;return R(g,x),m=!0,n!==void 0&&(n=x),l}return ye&&m||(w.f&be)!==0?g.v:h(g)})}var ze=$('<div id="svelte-announcer" aria-live="assertive" aria-atomic="true" style="position: absolute; left: 0; top: 0; clip: rect(0 0 0 0); clip-path: inset(50%); overflow: hidden; white-space: nowrap; width: 1px; height: 1px"><!></div>'),Fe=$("<!> <!>",1);function He(t,e){Re(e,!0);let s=p(e,"components",23,()=>[]),i=p(e,"data_0",3,null),c=p(e,"data_1",3,null);Oe(()=>e.stores.page.set(e.page)),Ae(()=>{e.stores,e.page,e.constructors,s(),e.form,i(),c(),e.stores.page.notify()});let r=L(!1),a=L(!1),n=L(null);Me(()=>{const f=e.stores.page.subscribe(()=>{h(r)&&(R(a,!0),Te().then(()=>{R(n,document.title||"untitled page",!0)}))});return R(r,!0),f});const u=j(()=>e.constructors[1]);var d=Fe(),o=O(d);{var v=f=>{const P=j(()=>e.constructors[0]);var m=k(),g=O(m);D(g,()=>h(P),(w,l)=>{B(l(w,{get data(){return i()},get form(){return e.form},get params(){return e.page.params},children:(b,x)=>{var Y=k(),re=O(Y);D(re,()=>h(u),(ae,ne)=>{B(ne(ae,{get data(){return c()},get form(){return e.form},get params(){return e.page.params}}),se=>s()[1]=se,()=>s()?.[1])}),S(b,Y)},$$slots:{default:!0}}),b=>s()[0]=b,()=>s()?.[0])}),S(f,m)},E=f=>{const P=j(()=>e.constructors[0]);var m=k(),g=O(m);D(g,()=>h(P),(w,l)=>{B(l(w,{get data(){return i()},get form(){return e.form},get params(){return e.page.params}}),b=>s()[0]=b,()=>s()?.[0])}),S(f,m)};C(o,f=>{e.constructors[1]?f(v):f(E,-1)})}var _=Ie(o,2);{var y=f=>{var P=ze(),m=Le(P);{var g=w=>{var l=pe();ke(()=>Be(l,h(n))),S(w,l)};C(m,w=>{h(a)&&w(g)})}je(P),S(f,P)};C(_,f=>{h(r)&&f(y)})}S(t,d),xe()}const et=Ge(He),tt=[()=>M(()=>import("../nodes/0.BYBfjxZ5.js"),__vite__mapDeps([0,1,2,3]),import.meta.url),()=>M(()=>import("../nodes/1.DM-iOsKD.js"),__vite__mapDeps([4,1,2,5,6,7]),import.meta.url)],rt=[],at={},te={handleError:(({error:t})=>{console.error(t)}),reroute:(()=>{}),transport:{}},Ze=Object.fromEntries(Object.entries(te.transport).map(([t,e])=>[t,e.decode])),nt=Object.fromEntries(Object.entries(te.transport).map(([t,e])=>[t,e.encode])),st=!1,it=(t,e)=>Ze[t](e),ot=()=>M(()=>import("../chunks/wbPk3Yxo.js"),[],import.meta.url).then(t=>t.default);export{it as decode,Ze as decoders,at as dictionary,nt as encoders,ot as get_error_template,st as hash,te as hooks,$e as matchers,tt as nodes,et as root,rt as server_loads};
@@ -0,0 +1 @@
1
+ import{l as o,a as r}from"../chunks/B88gKiyt.js";export{o as load_css,r as start};
@@ -1 +1 @@
1
- import{a as i,f as g}from"../chunks/rqnVXeyB.js";import{k as h,g as l,t as v,l as d,n as s,o as a,q as _}from"../chunks/2_TffmqH.js";import{s as o}from"../chunks/CMkIcmi1.js";import{s as x,p}from"../chunks/BlANKL2r.js";const k={get error(){return p.error},get status(){return p.status}};x.updated.check;const m=k;var $=g("<h1> </h1> <p> </p>",1);function w(n,c){h(c,!0);var t=$(),r=l(t),f=s(r,!0);a(r);var e=_(r,2),u=s(e,!0);a(e),v(()=>{o(f,m.status),o(u,m.error?.message)}),i(n,t),d()}export{w as component};
1
+ import{a as i,f as g}from"../chunks/rqnVXeyB.js";import{k as h,g as l,t as v,l as d,n as s,o as a,q as _}from"../chunks/2_TffmqH.js";import{s as o}from"../chunks/CMkIcmi1.js";import{s as x,p}from"../chunks/B88gKiyt.js";const k={get error(){return p.error},get status(){return p.status}};x.updated.check;const m=k;var $=g("<h1> </h1> <p> </p>",1);function w(n,c){h(c,!0);var t=$(),r=l(t),f=s(r,!0);a(r);var e=_(r,2),u=s(e,!0);a(e),v(()=>{o(f,m.status),o(u,m.error?.message)}),i(n,t),d()}export{w as component};
@@ -1 +1 @@
1
- {"version":"1785878631412"}
1
+ {"version":"1786099489883"}
package/build/handler.js CHANGED
@@ -2,9 +2,9 @@ import './shims.js';
2
2
  import 'node:fs';
3
3
  import 'node:path';
4
4
  import 'node:process';
5
- export { h as handler } from './server/chunks/handler-DurXhqww.js';
6
- import './server/chunks/index.js-BQnOaW3H.js';
7
- import './server/chunks/manifest.js-CCJDdahY.js';
5
+ export { h as handler } from './server/chunks/handler-VLy1sI9x.js';
6
+ import './server/chunks/index.js-CWgll4BT.js';
7
+ import './server/chunks/manifest.js-C2lkmNzz.js';
8
8
  import './env.js';
9
9
  import 'node:buffer';
10
10
  import 'node:crypto';
package/build/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import http from 'node:http';
2
2
  import fs__default from 'node:fs';
3
3
  import process from 'node:process';
4
- import { p as polka, h as handler, f as format_listening_address } from './server/chunks/handler-DurXhqww.js';
4
+ import { p as polka, h as handler, f as format_listening_address } from './server/chunks/handler-VLy1sI9x.js';
5
5
  import { env, timeout_env } from './env.js';
6
6
  import { rm } from 'node:fs/promises';
7
7
  import './shims.js';
@@ -11,8 +11,8 @@ import 'node:path';
11
11
  import 'node:timers';
12
12
  import 'node:querystring';
13
13
  import 'node:stream';
14
- import './server/chunks/index.js-BQnOaW3H.js';
15
- import './server/chunks/manifest.js-CCJDdahY.js';
14
+ import './server/chunks/index.js-CWgll4BT.js';
15
+ import './server/chunks/manifest.js-C2lkmNzz.js';
16
16
  import 'node:url';
17
17
 
18
18
  const path = env('SOCKET_PATH', false);
@@ -1,7 +1,7 @@
1
1
  const index = 1;
2
2
  let component_cache;
3
- const component = async () => component_cache ??= (await import('./error.svelte-B9R6O_Hn.js')).default;
4
- const imports = ["_app/immutable/nodes/1.BtbjYUHR.js","_app/immutable/chunks/rqnVXeyB.js","_app/immutable/chunks/2_TffmqH.js","_app/immutable/chunks/CMkIcmi1.js","_app/immutable/chunks/BlANKL2r.js","_app/immutable/chunks/B2EkC-sy.js"];
3
+ const component = async () => component_cache ??= (await import('./error.svelte-BTdVSWca.js')).default;
4
+ const imports = ["_app/immutable/nodes/1.DM-iOsKD.js","_app/immutable/chunks/rqnVXeyB.js","_app/immutable/chunks/2_TffmqH.js","_app/immutable/chunks/CMkIcmi1.js","_app/immutable/chunks/B88gKiyt.js","_app/immutable/chunks/B2EkC-sy.js"];
5
5
  const stylesheets = [];
6
6
  const fonts = [];
7
7
 
@@ -1,6 +1,6 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
2
- import { b as getAgentGatewayDiagnostics } from './agent-gateway-runtime-C7Kvvy0H.js';
3
- import { g as getHostConfig, a as getHostRegistrationDiagnostics, b as getHostPluginRegistryDiagnostics, c as getHostAdmissionDiagnostics, r as resolveCommunityPackageModule } from './registry-DO8ob5o1.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
+ import { b as getAgentGatewayDiagnostics } from './agent-gateway-runtime-DV-xLmJx.js';
3
+ import { g as getHostConfig, a as getKernelRuntimeSnapshot, b as getHostRegistrationDiagnostics, c as getHostPluginRegistryDiagnostics, d as getHostAdmissionDiagnostics, r as resolveCommunityPackageModule } from './registry-DIreA2IZ.js';
4
4
  import { r as readRuntimeConfigAdmin } from './aops-runtime-config-CHpDUCdE.js';
5
5
  import '@aopslabs/host-core';
6
6
  import '@aopslabs/manifest';
@@ -11,11 +11,14 @@ import 'node:url';
11
11
  import 'node:util';
12
12
  import './project-alias-BdnRxWft.js';
13
13
  import 'node:crypto';
14
- import './canonical-text-order-DbXJJnFD.js';
15
- import './admission-snapshot-C2wGfTWE.js';
14
+ import '@aopslabs/artifact-trust-contracts';
16
15
  import 'ajv';
17
16
  import 'zod';
18
17
  import 'node:fs';
18
+ import 'node:os';
19
+ import '@aopslabs/host-admission';
20
+ import '@aopslabs/host-auth';
21
+ import '@aopslabs/host-shell';
19
22
  import 'node:worker_threads';
20
23
  import 'pg';
21
24
 
@@ -50,6 +53,7 @@ function areHostAdminPluginDiagnosticsEnabled() {
50
53
  return getHostConfig().diagnostics?.exposePluginBootstrap !== false;
51
54
  }
52
55
  async function readHostAdminPluginsSnapshot() {
56
+ const kernel = await getKernelRuntimeSnapshot();
53
57
  const config = getHostConfig();
54
58
  const plugins = config.plugins ?? [];
55
59
  const providers = config.agentGateway?.catalog?.manifestProviders ?? [];
@@ -63,7 +67,14 @@ async function readHostAdminPluginsSnapshot() {
63
67
  registrations: getHostRegistrationDiagnostics(),
64
68
  agentGateway: getAgentGatewayDiagnostics(),
65
69
  storage: { postgres: readRuntimeConfigAdmin() },
66
- sources: []
70
+ sources: [],
71
+ kernel: {
72
+ profile: kernel.kernel.config.profile,
73
+ authority: kernel.kernel.authority.mode,
74
+ admission: kernel.kernel.admission.mode,
75
+ domainCount: kernel.registry.listDomains().length,
76
+ gateway: kernel.gateway.getDiagnostics()
77
+ }
67
78
  };
68
79
  }
69
80
  const GET = async ({ url }) => {
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { Effect } from 'effect';
3
3
  import { normalizeProjectmanFlowAction, createProjectmanBoardFlow, applyProjectmanTemplateFlow, createProjectmanTemplateFlow, updateProjectmanTemplateFlow, deleteProjectmanTemplateFlow, createProjectmanBoardColumnFlow, createProjectmanTaskFlow, updateProjectmanTaskFlow, moveProjectmanTaskFlow, repositionProjectmanTaskFlow, createProjectmanSprintFlow, updateProjectmanSprintPlanFlow, createProjectmanSprintMicrotaskFlow, updateProjectmanSprintMicrotaskStatusFlow, createProjectmanIssueFlow, updateProjectmanIssueFlow, createProjectmanFeedbackFlow, updateProjectmanFeedbackFlow, convertProjectmanFeedbackToIssueFlow, convertProjectmanFeedbackToTaskFlow, inferProjectmanFlowErrorStatus } from '@aopslabs/domain-product-projectman';
4
4
  import './aops-runtime-config-CHpDUCdE.js';
@@ -1,18 +1,20 @@
1
1
  import { createSvelteKitPluginHandler } from '@aopslabs/host-adapter-sveltekit';
2
- import { j as json } from './index.js-BQnOaW3H.js';
3
- import { d as checkHostDomainAdmission, e as getHostPluginRegistry } from './registry-DO8ob5o1.js';
2
+ import { checkDomainAdmission } from '@aopslabs/host-admission';
3
+ import { j as json } from './index.js-CWgll4BT.js';
4
+ import { a as getKernelRuntimeSnapshot, e as getHostPluginRegistry } from './registry-DIreA2IZ.js';
4
5
  import { a as toSafeDiagnosticLabel, n as normalizePluginFailure, t as toSafePluginFailureLogDetails, i as inferFailureStatusFromPayload } from './plugin-error-normalize-DNeRsopQ.js';
5
6
  import { a as attachResolvedProjectScope, r as resolveHostRequestContext } from './request-context-9wzBoKrz.js';
7
+ import 'node:fs';
8
+ import 'node:os';
6
9
  import 'node:path';
7
- import 'node:module';
8
10
  import 'node:url';
9
- import '@aopslabs/host-core';
11
+ import '@aopslabs/host-auth';
12
+ import '@aopslabs/host-shell';
13
+ import 'node:worker_threads';
14
+ import '@aopslabs/artifact-trust-contracts';
10
15
  import './aops-runtime-config-CHpDUCdE.js';
11
- import 'node:fs';
12
16
  import 'pg';
13
- import 'node:worker_threads';
14
- import './admission-snapshot-C2wGfTWE.js';
15
- import 'node:crypto';
17
+ import '@aopslabs/host-core';
16
18
  import '@aopslabs/xf-dm-kits/appConfig';
17
19
  import '@aopslabs/xf-dm-kits';
18
20
  import '@aopslabs/domain-kit-agentspace';
@@ -88,7 +90,8 @@ async function normalizePluginErrorResponse(response) {
88
90
  const wrappedHandler = async (event) => {
89
91
  await attachResolvedProjectScope(event);
90
92
  const domain = String(event.params.domain ?? "").trim().toLowerCase();
91
- const admission = checkHostDomainAdmission(domain);
93
+ const kernel = await getKernelRuntimeSnapshot();
94
+ const admission = checkDomainAdmission(await kernel.kernel.admission.getSnapshot(), domain);
92
95
  if (!admission.allowed) {
93
96
  return json(
94
97
  { ok: false, error: "domain_not_available", domain, reason: admission.reason },
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { r as readRuntimeConfigAdmin, g as getResolvedAopsServerRuntimeConfig } from './aops-runtime-config-CHpDUCdE.js';
3
3
  import { g as getAuthProvider } from './auth-provider-C07OUlnz.js';
4
4
  import { o as okResult } from './xf-result-BRDjvftr.js';
@@ -1,23 +1,26 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
2
- import { g as getAgentDiscoveryDocument } from './discovery-BvDEgiqC.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
+ import { g as getAgentDiscoveryDocument } from './discovery-DL0RzVks.js';
3
3
  import { r as resolveRequestBaseUrl } from './request-base-url-zKJpVUv5.js';
4
- import './agent-gateway-runtime-C7Kvvy0H.js';
4
+ import './agent-gateway-runtime-DV-xLmJx.js';
5
5
  import '@aopslabs/host-core';
6
6
  import '@aopslabs/manifest';
7
- import './registry-DO8ob5o1.js';
7
+ import './registry-DIreA2IZ.js';
8
+ import 'node:fs';
9
+ import 'node:os';
8
10
  import 'node:path';
9
- import 'node:module';
10
11
  import 'node:url';
12
+ import '@aopslabs/host-admission';
13
+ import '@aopslabs/host-auth';
14
+ import '@aopslabs/host-shell';
15
+ import 'node:worker_threads';
16
+ import '@aopslabs/artifact-trust-contracts';
11
17
  import './aops-runtime-config-CHpDUCdE.js';
12
- import 'node:fs';
13
18
  import 'pg';
14
- import 'node:worker_threads';
15
- import './admission-snapshot-C2wGfTWE.js';
16
- import 'node:crypto';
17
19
  import 'node:child_process';
20
+ import 'node:module';
18
21
  import 'node:util';
19
22
  import './project-alias-BdnRxWft.js';
20
- import './canonical-text-order-DbXJJnFD.js';
23
+ import 'node:crypto';
21
24
  import 'ajv';
22
25
  import 'zod';
23
26
  import './auth-provider-C07OUlnz.js';
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { t as testRuntimeConfigAdminTarget, g as getResolvedAopsServerRuntimeConfig } from './aops-runtime-config-CHpDUCdE.js';
3
3
  import { o as okResult } from './xf-result-BRDjvftr.js';
4
4
  import 'node:fs';
@@ -1,23 +1,26 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
2
- import { a as getAgentToolDetailDocument } from './discovery-BvDEgiqC.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
+ import { a as getAgentToolDetailDocument } from './discovery-DL0RzVks.js';
3
3
  import { r as resolveRequestBaseUrl } from './request-base-url-zKJpVUv5.js';
4
- import './agent-gateway-runtime-C7Kvvy0H.js';
4
+ import './agent-gateway-runtime-DV-xLmJx.js';
5
5
  import '@aopslabs/host-core';
6
6
  import '@aopslabs/manifest';
7
- import './registry-DO8ob5o1.js';
7
+ import './registry-DIreA2IZ.js';
8
+ import 'node:fs';
9
+ import 'node:os';
8
10
  import 'node:path';
9
- import 'node:module';
10
11
  import 'node:url';
12
+ import '@aopslabs/host-admission';
13
+ import '@aopslabs/host-auth';
14
+ import '@aopslabs/host-shell';
15
+ import 'node:worker_threads';
16
+ import '@aopslabs/artifact-trust-contracts';
11
17
  import './aops-runtime-config-CHpDUCdE.js';
12
- import 'node:fs';
13
18
  import 'pg';
14
- import 'node:worker_threads';
15
- import './admission-snapshot-C2wGfTWE.js';
16
- import 'node:crypto';
17
19
  import 'node:child_process';
20
+ import 'node:module';
18
21
  import 'node:util';
19
22
  import './project-alias-BdnRxWft.js';
20
- import './canonical-text-order-DbXJJnFD.js';
23
+ import 'node:crypto';
21
24
  import 'ajv';
22
25
  import 'zod';
23
26
  import './auth-provider-C07OUlnz.js';
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { o as okResult } from './xf-result-BRDjvftr.js';
3
3
 
4
4
  const GET = async ({ locals }) => {
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { t as testRuntimeConfigAdminTarget } from './aops-runtime-config-CHpDUCdE.js';
3
3
  import { o as okResult, e as errResult } from './xf-result-BRDjvftr.js';
4
4
  import 'node:fs';
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
 
3
3
  const API_ROOT_ERROR = {
4
4
  ok: false,
@@ -1,23 +1,26 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
2
- import { g as getAgentGateway } from './agent-gateway-runtime-C7Kvvy0H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
+ import { g as getAgentGateway } from './agent-gateway-runtime-DV-xLmJx.js';
3
3
  import { r as resolveRequestBaseUrl } from './request-base-url-zKJpVUv5.js';
4
4
  import { g as getAuthProvider, i as isTrustedLocalAuthProvider } from './auth-provider-C07OUlnz.js';
5
5
  import '@aopslabs/host-core';
6
6
  import '@aopslabs/manifest';
7
- import './registry-DO8ob5o1.js';
7
+ import './registry-DIreA2IZ.js';
8
+ import 'node:fs';
9
+ import 'node:os';
8
10
  import 'node:path';
9
- import 'node:module';
10
11
  import 'node:url';
12
+ import '@aopslabs/host-admission';
13
+ import '@aopslabs/host-auth';
14
+ import '@aopslabs/host-shell';
15
+ import 'node:worker_threads';
16
+ import '@aopslabs/artifact-trust-contracts';
11
17
  import './aops-runtime-config-CHpDUCdE.js';
12
- import 'node:fs';
13
18
  import 'pg';
14
- import 'node:worker_threads';
15
- import './admission-snapshot-C2wGfTWE.js';
16
- import 'node:crypto';
17
19
  import 'node:child_process';
20
+ import 'node:module';
18
21
  import 'node:util';
19
22
  import './project-alias-BdnRxWft.js';
20
- import './canonical-text-order-DbXJJnFD.js';
23
+ import 'node:crypto';
21
24
  import 'ajv';
22
25
  import 'zod';
23
26
 
@@ -1,39 +1,35 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
2
- import { z } from 'zod';
3
- import { g as getAgentGateway } from './agent-gateway-runtime-C7Kvvy0H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
+ import { HostGatewayError, parseStrictInvokeEnvelope } from '@aopslabs/host-gateway';
3
+ import { i as invokeKernelAgentTool } from './agent-gateway-runtime-DV-xLmJx.js';
4
4
  import { n as normalizePluginFailure, t as toSafePluginFailureLogDetails, i as inferFailureStatusFromPayload, c as classifyInvokeFailureMessage } from './plugin-error-normalize-DNeRsopQ.js';
5
5
  import { a as attachResolvedProjectScope, r as resolveHostRequestContext } from './request-context-9wzBoKrz.js';
6
6
  import '@aopslabs/host-core';
7
7
  import '@aopslabs/manifest';
8
- import './registry-DO8ob5o1.js';
8
+ import './registry-DIreA2IZ.js';
9
+ import 'node:fs';
10
+ import 'node:os';
9
11
  import 'node:path';
10
- import 'node:module';
11
12
  import 'node:url';
13
+ import '@aopslabs/host-admission';
14
+ import '@aopslabs/host-auth';
15
+ import '@aopslabs/host-shell';
16
+ import 'node:worker_threads';
17
+ import '@aopslabs/artifact-trust-contracts';
12
18
  import './aops-runtime-config-CHpDUCdE.js';
13
- import 'node:fs';
14
19
  import 'pg';
15
- import 'node:worker_threads';
16
- import './admission-snapshot-C2wGfTWE.js';
17
- import 'node:crypto';
18
20
  import 'node:child_process';
21
+ import 'node:module';
19
22
  import 'node:util';
20
23
  import './project-alias-BdnRxWft.js';
21
- import './canonical-text-order-DbXJJnFD.js';
24
+ import 'node:crypto';
22
25
  import 'ajv';
26
+ import 'zod';
23
27
  import '@aopslabs/xf-dm-kits/appConfig';
24
28
  import '@aopslabs/xf-dm-kits';
25
29
  import '@aopslabs/domain-kit-agentspace';
26
30
  import './xf-result-BRDjvftr.js';
27
31
  import 'effect';
28
32
 
29
- const invokeEnvelopeSchema = z.object({
30
- sourceId: z.string().trim().min(1).optional(),
31
- input: z.unknown().optional(),
32
- preview: z.boolean().optional(),
33
- apply: z.boolean().optional(),
34
- confirm: z.boolean().optional(),
35
- idempotencyKey: z.string().trim().min(1).max(200).optional()
36
- }).strict();
37
33
  function isRecord(value) {
38
34
  return Boolean(value) && typeof value === "object" && !Array.isArray(value);
39
35
  }
@@ -53,9 +49,6 @@ function sanitizeInvokeHeaders(input) {
53
49
  }
54
50
  return headers;
55
51
  }
56
- function hasClientProvidedContext(input) {
57
- return isRecord(input) && Object.prototype.hasOwnProperty.call(input, "context");
58
- }
59
52
  function resolveActivitySourceKind(event) {
60
53
  const candidate = String(event.request.headers.get("x-activity-source-kind") ?? "").trim().toLowerCase();
61
54
  if (candidate === "aops-cli" || candidate === "desktop" || candidate === "runner" || candidate === "system") {
@@ -67,47 +60,14 @@ async function parseInvokePayload(event) {
67
60
  try {
68
61
  const rawText = await event.request.text();
69
62
  if (!rawText.trim()) {
70
- return { ok: true, input: void 0 };
63
+ return { ok: false, error: "invalid_input", message: "invoke_envelope_required" };
71
64
  }
72
65
  const rawPayload = JSON.parse(rawText);
73
- const shouldParseEnvelope = isRecord(rawPayload) && ("input" in rawPayload || "preview" in rawPayload || "apply" in rawPayload || "confirm" in rawPayload || "idempotencyKey" in rawPayload || Object.keys(rawPayload).every(
74
- (key) => key === "sourceId" || key === "input" || key === "preview" || key === "apply" || key === "confirm" || key === "idempotencyKey"
75
- ));
76
- if (!shouldParseEnvelope) {
77
- if (hasClientProvidedContext(rawPayload)) {
78
- return {
79
- ok: false,
80
- error: "invalid_input",
81
- message: "invalid_invoke_payload:context_not_allowed"
82
- };
83
- }
84
- return { ok: true, input: rawPayload };
85
- }
86
- const parsedEnvelope = invokeEnvelopeSchema.safeParse(rawPayload);
87
- if (!parsedEnvelope.success) {
88
- return {
89
- ok: false,
90
- error: "invalid_input",
91
- message: `invalid_invoke_payload:${parsedEnvelope.error.issues[0]?.message ?? "invalid_envelope"}`
92
- };
93
- }
94
- if (hasClientProvidedContext(parsedEnvelope.data.input)) {
95
- return {
96
- ok: false,
97
- error: "invalid_input",
98
- message: "invalid_invoke_payload:input.context_not_allowed"
99
- };
66
+ return { ok: true, envelope: parseStrictInvokeEnvelope(rawPayload) };
67
+ } catch (error) {
68
+ if (error instanceof HostGatewayError) {
69
+ return { ok: false, error: error.code, message: error.message };
100
70
  }
101
- return {
102
- ok: true,
103
- sourceId: parsedEnvelope.data.sourceId?.trim().toLowerCase(),
104
- input: parsedEnvelope.data.input,
105
- preview: parsedEnvelope.data.preview,
106
- apply: parsedEnvelope.data.apply,
107
- confirm: parsedEnvelope.data.confirm,
108
- idempotencyKey: parsedEnvelope.data.idempotencyKey?.trim()
109
- };
110
- } catch {
111
71
  return {
112
72
  ok: false,
113
73
  error: "invalid_input",
@@ -121,24 +81,19 @@ const POST = async (event) => {
121
81
  if (!toolId) {
122
82
  return json({ ok: false, error: "missing_tool_id" }, { status: 400 });
123
83
  }
124
- const gateway = getAgentGateway();
125
84
  const parsedPayload = await parseInvokePayload(event);
126
85
  if (!parsedPayload.ok) {
127
86
  return json({ ok: false, error: parsedPayload.error, message: parsedPayload.message }, { status: 400 });
128
87
  }
129
88
  try {
130
- const result = await gateway.invokeTool({
89
+ const result = await invokeKernelAgentTool({
131
90
  toolId,
132
- sourceId: parsedPayload.sourceId,
133
- input: parsedPayload.input,
134
- preview: parsedPayload.preview,
135
- apply: parsedPayload.apply,
136
- confirm: parsedPayload.confirm,
137
- idempotencyKey: parsedPayload.idempotencyKey,
91
+ envelope: parsedPayload.envelope,
138
92
  context: {
139
93
  ...resolveHostRequestContext(event),
140
94
  activitySourceKind: resolveActivitySourceKind(event)
141
- }
95
+ },
96
+ requestHeaders: event.request.headers
142
97
  });
143
98
  const normalized = normalizePluginFailure(result.status, result.data);
144
99
  if (normalized.sanitized) {
@@ -160,6 +115,12 @@ const POST = async (event) => {
160
115
  { status: effectiveStatus, headers: sanitizeInvokeHeaders(result.headers) }
161
116
  );
162
117
  } catch (error) {
118
+ if (error instanceof HostGatewayError) {
119
+ return json(
120
+ { ok: false, error: error.code, message: error.message, ...error.details ? { details: error.details } : {} },
121
+ { status: error.status }
122
+ );
123
+ }
163
124
  const message = normalizeErrorMessage(error);
164
125
  const classification = classifyInvokeFailureMessage(message);
165
126
  return json(
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { r as readRuntimeConfigAdmin } from './aops-runtime-config-CHpDUCdE.js';
3
3
  import { o as okResult } from './xf-result-BRDjvftr.js';
4
4
  import 'node:fs';
@@ -1,4 +1,4 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
2
  import { Effect } from 'effect';
3
3
  import { normalizeDocmanFlowAction, saveDocmanGroupFlow, saveDocmanDocumentFlow, saveDocmanSectionFlow, copyDocmanSectionFlow, createLinkedDocmanSection, linkExistingDocmanSection, linkExistingDocmanPageVersion, updateDocmanDocumentSectionLinksFlow, updateDocmanSectionPageLinksFlow, saveDocmanPageVersionDraftFlow, updateDocmanDocumentVersionFlow, updateDocmanPageFlow, copyDocmanPageFlow, createDocmanDocumentVersionFlow, createDocmanPageWithInitialVersionFlow, createLinkedDocmanPage, inferDocmanFlowErrorStatus } from '@aopslabs/domain-product-docman';
4
4
  import { a as attachResolvedProjectScope, b as resolveProjectScopeFromLocals } from './request-context-9wzBoKrz.js';
@@ -1,7 +1,7 @@
1
- import { j as json } from './index.js-BQnOaW3H.js';
2
- import { g as getAgentGateway } from './agent-gateway-runtime-C7Kvvy0H.js';
3
- import { b as buildAgentDiscoveryDocument } from './discovery-BvDEgiqC.js';
4
- import { g as getHostConfig } from './registry-DO8ob5o1.js';
1
+ import { j as json } from './index.js-CWgll4BT.js';
2
+ import { g as getAgentGateway } from './agent-gateway-runtime-DV-xLmJx.js';
3
+ import { b as buildAgentDiscoveryDocument } from './discovery-DL0RzVks.js';
4
+ import { g as getHostConfig } from './registry-DIreA2IZ.js';
5
5
  import { r as resolveRequestBaseUrl } from './request-base-url-zKJpVUv5.js';
6
6
  import '@aopslabs/host-core';
7
7
  import '@aopslabs/manifest';
@@ -12,15 +12,18 @@ import 'node:url';
12
12
  import 'node:util';
13
13
  import './project-alias-BdnRxWft.js';
14
14
  import 'node:crypto';
15
- import './canonical-text-order-DbXJJnFD.js';
16
- import './admission-snapshot-C2wGfTWE.js';
15
+ import '@aopslabs/artifact-trust-contracts';
17
16
  import 'ajv';
18
17
  import 'zod';
19
18
  import './auth-provider-C07OUlnz.js';
20
- import './aops-runtime-config-CHpDUCdE.js';
21
19
  import 'node:fs';
22
- import 'pg';
20
+ import 'node:os';
21
+ import '@aopslabs/host-admission';
22
+ import '@aopslabs/host-auth';
23
+ import '@aopslabs/host-shell';
23
24
  import 'node:worker_threads';
25
+ import './aops-runtime-config-CHpDUCdE.js';
26
+ import 'pg';
24
27
 
25
28
  const AGENT_FLOW_OVERVIEW = {
26
29
  version: "1.0",