geneseed 4.9.4 → 4.14.0
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/CHANGELOG.md +106 -0
- package/README.md +16 -2
- package/SHIPPED.md +1 -1
- package/docs/README.md +1 -1
- package/docs/concepts/collaboration.md +1 -1
- package/docs/concepts/enforcement-table.md +1 -1
- package/docs/concepts/foreman-mode.md +1 -1
- package/docs/concepts/kits.md +91 -0
- package/docs/concepts/loop-branch.md +1 -1
- package/docs/concepts/loop-bricks.md +1 -1
- package/docs/concepts/loop-contracts.md +1 -1
- package/docs/concepts/loop-gates.md +1 -1
- package/docs/concepts/loop-notes.md +1 -1
- package/docs/concepts/loop-risk.md +1 -1
- package/docs/concepts/loop-templates.md +1 -1
- package/docs/concepts/loops.md +1 -1
- package/docs/concepts/lsp.md +1 -1
- package/docs/concepts/skills.md +1 -1
- package/docs/extending.md +107 -4
- package/docs/guides/install-scripted.md +1 -1
- package/docs/guides/run-anywhere.md +2 -2
- package/docs/guides/upgrade.md +2 -2
- package/docs/reference/glossary.md +1 -0
- package/docs/reference/troubleshoot-install.md +1 -1
- package/docs/web-ui.md +9 -0
- package/harness.config.json +1 -1
- package/js/build/args.mjs +27 -6
- package/js/build/driver.mjs +29 -8
- package/js/build/emit-claude.mjs +3 -1
- package/js/build/generate.mjs +10 -5
- package/js/build/render.mjs +94 -11
- package/js/build/source.mjs +117 -4
- package/js/cli-table.json +15 -0
- package/js/hosts/installs.mjs +35 -2
- package/js/hosts/link.mjs +88 -1
- package/js/hosts/native.mjs +14 -4
- package/js/inspect/checks-authoring.mjs +6 -3
- package/js/inspect/checks-build.mjs +15 -3
- package/js/inspect/checks-counts.mjs +153 -6
- package/js/inspect/checks-repo.mjs +95 -20
- package/js/inspect/cost.mjs +1 -1
- package/js/inspect/diff.mjs +56 -8
- package/js/inspect/inventory.mjs +2 -0
- package/js/inspect/status.mjs +44 -3
- package/js/inspect/validate.mjs +3 -3
- package/js/lib/prompt.mjs +19 -2
- package/js/maintain/setup.mjs +111 -23
- package/js/maintain/update.mjs +3 -3
- package/js/web/actions.mjs +38 -6
- package/js/web/api.mjs +76 -17
- package/js/web/catalog.mjs +17 -2
- package/js/web/handler.mjs +1 -0
- package/js/web/routes.mjs +2 -1
- package/js/web/server.mjs +11 -5
- package/js/web/state.mjs +38 -3
- package/package.json +1 -1
- package/registry.json +91 -0
- package/src/AGENT.md.tmpl +7 -7
- package/src/agents/_self-improvement.md +11 -0
- package/src/agents/_template.md +1 -8
- package/src/agents/advocate.md +1 -8
- package/src/agents/architect.md +1 -8
- package/src/agents/developer.md +1 -8
- package/src/agents/devops-engineer.md +37 -0
- package/src/agents/docker-expert.md +37 -0
- package/src/agents/docs.md +1 -8
- package/src/agents/empiricist.md +1 -8
- package/src/agents/explorer.md +1 -8
- package/src/agents/framer.md +1 -8
- package/src/agents/historian.md +1 -8
- package/src/agents/kubernetes-specialist.md +37 -0
- package/src/agents/memory-curator.md +1 -8
- package/src/agents/operator.md +1 -8
- package/src/agents/performance.md +1 -8
- package/src/agents/pragmatist.md +1 -8
- package/src/agents/react-engineer.md +38 -0
- package/src/agents/react-reviewer.md +42 -0
- package/src/agents/researcher.md +5 -10
- package/src/agents/reviewer.md +3 -8
- package/src/agents/security.md +1 -8
- package/src/agents/skeptic.md +1 -8
- package/src/agents/spring-boot-engineer.md +40 -0
- package/src/agents/spring-reviewer.md +41 -0
- package/src/agents/spring-security.md +42 -0
- package/src/agents/steward.md +1 -8
- package/src/agents/tester.md +1 -8
- package/src/agents/user-advocate.md +1 -8
- package/src/agents/visionary.md +1 -8
- package/src/kits/react/rules.md +13 -0
- package/src/kits/react.json +18 -0
- package/src/kits/spring-boot/rules.md +10 -0
- package/src/kits/spring-boot.json +23 -0
- package/src/licenses/everything-claude-code.txt +21 -0
- package/src/licenses/mattpocock-skills.txt +21 -0
- package/src/licenses/piomin-spring-boot.txt +190 -0
- package/src/licenses/superpowers.txt +21 -0
- package/src/licenses/vibe-wise.txt +21 -0
- package/src/skills/_self-improvement.md +22 -5
- package/src/skills/brainstorm/builder-check.md +2 -0
- package/src/skills/brainstorm.md +11 -2
- package/src/skills/codebase-design.md +10 -2
- package/src/skills/daydream/VENDOR.md +7 -7
- package/src/skills/debug.md +6 -2
- package/src/skills/develop.md +6 -2
- package/src/skills/geneseed-code-review.md +6 -2
- package/src/skills/git-history.md +2 -0
- package/src/skills/handoff.md +3 -1
- package/src/skills/learn-mode.md +3 -2
- package/src/skills/parallel-agents.md +5 -1
- package/src/skills/pipeline.md +2 -0
- package/src/skills/plan.md +9 -2
- package/src/skills/prototype.md +6 -2
- package/src/skills/react/a11y.md +33 -0
- package/src/skills/react/vite.md +35 -0
- package/src/skills/react/webpack.md +40 -0
- package/src/skills/react-testing.md +68 -0
- package/src/skills/react-view-transitions/AGENTS.md +646 -221
- package/src/skills/react-view-transitions/SKILL.md +28 -16
- package/src/skills/react-view-transitions/VENDOR.md +10 -8
- package/src/skills/react-view-transitions/references/css-recipes.md +72 -2
- package/src/skills/react-view-transitions/references/implementation.md +14 -26
- package/src/skills/react-view-transitions/references/nextjs.md +94 -37
- package/src/skills/react-view-transitions/references/patterns.md +60 -48
- package/src/skills/react-view-transitions/references/troubleshooting.md +47 -0
- package/src/skills/react.md +63 -0
- package/src/skills/research.md +6 -2
- package/src/skills/review-response.md +2 -0
- package/src/skills/rule.md +6 -2
- package/src/skills/ship.md +8 -4
- package/src/skills/skill-forge.md +11 -5
- package/src/skills/spring-boot/cloud.md +103 -0
- package/src/skills/spring-boot/java-modern.md +71 -0
- package/src/skills/spring-boot/logging.md +89 -0
- package/src/skills/spring-boot/security.md +112 -0
- package/src/skills/spring-boot/web.md +112 -0
- package/src/skills/spring-boot.md +57 -0
- package/src/skills/spring-data-jpa/patterns.md +68 -0
- package/src/skills/spring-data-jpa.md +81 -0
- package/src/skills/spring-testing.md +93 -0
- package/src/skills/wayfinder.md +8 -2
- package/src/skills/wiki.md +18 -5
- package/src/upstreams.json +66 -0
- package/themes/_TEMPLATE.json +13 -0
- package/themes/biker.json +13 -0
- package/themes/commentator.json +13 -0
- package/themes/cyberpunk.json +13 -0
- package/themes/gamer.json +13 -0
- package/themes/imperial.json +13 -0
- package/themes/joker.json +13 -0
- package/themes/marvin.json +13 -0
- package/themes/mean.json +13 -0
- package/themes/military.json +13 -0
- package/themes/neutral.json +13 -0
- package/themes/pirate.json +13 -0
- package/themes/sports.json +13 -0
- package/themes/verstappen.json +13 -0
- package/themes/wizard.json +13 -0
- package/web/dist/assets/Activity-44rbWUQI.js +1 -0
- package/web/dist/assets/ActivityDetail-Dk9k893a.js +1 -0
- package/web/dist/assets/Dashboard-DCoUN60W.js +2 -0
- package/web/dist/assets/{Docs-tDW7i7mo.js → Docs-C_je2lRG.js} +3 -3
- package/web/dist/assets/FilterInput-CZREvrjX.js +1 -0
- package/web/dist/assets/GreenhouseView-BXAOIznW.js +2 -0
- package/web/dist/assets/Installs-DAXF403D.js +3 -0
- package/web/dist/assets/JournalView-DZ184wKB.js +1 -0
- package/web/dist/assets/KitApply-pjhvGha0.js +1 -0
- package/web/dist/assets/Kits-BCCKjSIY.js +1 -0
- package/web/dist/assets/{Laws-BA3CzUf5.js → Laws-BgBUpRkE.js} +1 -1
- package/web/dist/assets/Library-CW0Zl6RF.js +1 -0
- package/web/dist/assets/Loops-BvFOzjEw.js +2 -0
- package/web/dist/assets/{Markdown-iHvBrpRN.js → Markdown-zaXXXHz9.js} +13 -13
- package/web/dist/assets/OperatorHudView-Bs4unPNi.js +2 -0
- package/web/dist/assets/Personal-C23XaT-a.js +1 -0
- package/web/dist/assets/Tabs-b2XFu4OS.js +1 -0
- package/web/dist/assets/activity-Jw8XcPiP.js +1 -0
- package/web/dist/assets/api-BfpZmUMI.js +1 -0
- package/web/dist/assets/{drawable-CyLe1gtW.js → drawable-BERkKhx_.js} +1 -1
- package/web/dist/assets/index-C9R_bRw_.js +2 -0
- package/web/dist/assets/{index-BCJz4_8C.css → index-jYlWihN-.css} +1 -1
- package/web/dist/assets/{react-BOF6yL40.js → react-DlYQp10C.js} +1 -1
- package/web/dist/assets/rolldown-runtime-hePW80VL.js +1 -0
- package/web/dist/assets/sections-ChwaobfW.js +1 -0
- package/web/dist/assets/usePoll-bDFN-Hr6.js +1 -0
- package/web/dist/index.html +6 -5
- package/web/dist/assets/Activity-C8sZVIUU.js +0 -1
- package/web/dist/assets/ActivityDetail-Cc6vWUS4.js +0 -1
- package/web/dist/assets/Dashboard-C5ATa3ow.js +0 -2
- package/web/dist/assets/FilterInput-zLFXoSt6.js +0 -1
- package/web/dist/assets/GreenhouseView-zk2Uzc3A.js +0 -2
- package/web/dist/assets/Installs-CB_rvbBP.js +0 -3
- package/web/dist/assets/JournalView-Bfj27XHC.js +0 -1
- package/web/dist/assets/Library-BWwiy9Vb.js +0 -1
- package/web/dist/assets/Loops-DaPk-ckL.js +0 -2
- package/web/dist/assets/OperatorHudView-CyiGhiHk.js +0 -2
- package/web/dist/assets/Personal-Bwd27CmT.js +0 -1
- package/web/dist/assets/Tabs-BOD7Kaz1.js +0 -1
- package/web/dist/assets/activity-DvPxoS4Y.js +0 -1
- package/web/dist/assets/api-CiXlkbe0.js +0 -1
- package/web/dist/assets/index-DQXG_mqo.js +0 -2
- package/web/dist/assets/sections-BET3c1WT.js +0 -1
- package/web/dist/assets/usePoll-NSTzLOF4.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as e}from"./sections-BET3c1WT.js";var t=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.for(`react.view_transition`),m=Symbol.iterator;function h(e){return typeof e!=`object`||!e?null:(e=m&&e[m]||e[`@@iterator`],typeof e==`function`?e:null)}var g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,v={};function y(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function b(){}b.prototype=y.prototype;function ee(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}var te=ee.prototype=new b;te.constructor=ee,_(te,y.prototype),te.isPureReactComponent=!0;var ne=Array.isArray;function re(){}var x={H:null,A:null,T:null,S:null},ie=Object.prototype.hasOwnProperty;function S(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function ae(e,t){return S(e.type,t,e.props)}function oe(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function se(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var ce=/\/+/g;function le(e,t){return typeof e==`object`&&e&&e.key!=null?se(``+e.key):t.toString(36)}function ue(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(re,re):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function de(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,de(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+le(e,0):a,ne(o)?(i=``,c!=null&&(i=c.replace(ce,`$&/`)+`/`),de(o,r,i,``,function(e){return e})):o!=null&&(oe(o)&&(o=ae(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(ce,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(ne(e))for(var u=0;u<e.length;u++)a=e[u],s=l+le(a,u),c+=de(a,r,i,s,o);else if(u=h(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+le(a,u++),c+=de(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return de(ue(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function fe(e,t,n){if(e==null)return e;var r=[],i=0;return de(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function pe(e){if(e._status===-1){var t=e._result,n=t();n.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t,n.status===void 0&&(n.status=`fulfilled`,n.value=t))},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t,n.status===void 0&&(n.status=`rejected`,n.reason=t))}),e._status===-1&&(e._status=0,e._result=n)}if(e._status===1)return e._result.default;throw e._result}var me=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)};function he(e){var t=x.T,n={};n.types=t===null?null:t.types,x.T=n;try{var r=e(),i=x.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(re,me)}catch(e){me(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),x.T=t}}function ge(e){var t=x.T;if(t!==null){var n=t.types;n===null?t.types=[e]:n.indexOf(e)===-1&&n.push(e)}else he(ge.bind(null,e))}var _e={map:fe,forEach:function(e,t,n){fe(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return fe(e,function(){t++}),t},toArray:function(e){return fe(e,function(e){return e})||[]},only:function(e){if(!oe(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=_e,e.Component=y,e.Fragment=r,e.Profiler=a,e.PureComponent=ee,e.StrictMode=i,e.Suspense=l,e.ViewTransition=p,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}},e.addTransitionType=ge,e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=_({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!ie.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return S(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)ie.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return S(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=oe,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:pe}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=he,e.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()},e.use=function(e){return x.H.use(e)},e.useActionState=function(e,t,n){return x.H.useActionState(e,t,n)},e.useCallback=function(e,t){return x.H.useCallback(e,t)},e.useContext=function(e){return x.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return x.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return x.H.useEffect(e,t)},e.useEffectEvent=function(e){return x.H.useEffectEvent(e)},e.useId=function(){return x.H.useId()},e.useImperativeHandle=function(e,t,n){return x.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return x.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return x.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return x.H.useMemo(e,t)},e.useOptimistic=function(e,t){return x.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return x.H.useReducer(e,t,n)},e.useRef=function(e){return x.H.useRef(e)},e.useState=function(e){return x.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return x.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return x.H.useTransition()},e.version=`19.3.1`})),n=e(((e,n)=>{n.exports=t()})),r=e((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function ee(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,te||(te=!0,ae());else{var t=n(l);t!==null&&ce(ee,t.startTime-e)}}}var te=!1,ne=-1,re=5,x=-1;function ie(){return g?!0:!(e.unstable_now()-x<re)}function S(){if(g=!1,te){var t=e.unstable_now();x=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(ne),ne=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&ie());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ce(ee,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?ae():te=!1}}}var ae;if(typeof y==`function`)ae=function(){y(S)};else if(typeof MessageChannel<`u`){var oe=new MessageChannel,se=oe.port2;oe.port1.onmessage=S,ae=function(){se.postMessage(null)}}else ae=function(){_(S,0)};function ce(t,n){ne=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):re=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(ne),ne=-1):h=!0,ce(ee,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,te||(te=!0,ae()))),r},e.unstable_shouldYield=ie,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),i=e(((e,t)=>{t.exports=r()})),a=e((e=>{var t=n();function r(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function i(){}var a={d:{f:i,r:function(){throw Error(r(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},o=Symbol.for(`react.portal`),s=Symbol.for(`react.recoverable`),c=Symbol.for(`react.optimistic_key`);function l(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:r==null?null:r===c?c:``+r,children:e,containerInfo:t,implementation:n}}var u=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function d(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=a,e.browser=function(e){return{$$typeof:s,_reason:e}},e.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(r(299));return l(e,t,null,n)},e.flushSync=function(e){var t=u.T,n=a.p;try{if(u.T=null,a.p=2,e)return e()}finally{u.T=t,a.p=n,a.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,a.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&a.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=d(n,t.crossOrigin),i=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?a.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:i,fetchPriority:o}):n===`script`&&a.d.X(e,{crossOrigin:r,integrity:i,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=d(t.as,t.crossOrigin);a.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0})}}else t??a.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=d(n,t.crossOrigin);a.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=d(t.as,t.crossOrigin);a.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0})}else a.d.m(e)}},e.requestFormReset=function(e){a.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return u.H.useFormState(e,t,n)},e.useFormStatus=function(){return u.H.useHostTransitionStatus()},e.version=`19.3.1`})),o=e(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=a()})),s=e((e=>{var t=i(),r=n(),a=o();function s(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function c(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function l(e){for(var t=e,n=t;n&&!n.alternate;)t=n,t.flags&4098&&(e=t.return),n=t.return;for(;t.return;)t=t.return;return t.tag===3?e:null}function u(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function d(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function f(e){if(l(e)!==e)throw Error(s(188))}function p(e){var t=e.alternate;if(!t){if(t=l(e),t===null)throw Error(s(188));return t===e?e:null}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var a=i.alternate;if(a===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===n)return f(i),e;if(a===r)return f(i),t;a=a.sibling}throw Error(s(188))}if(n.return!==r.return)n=i,r=a;else{for(var o=!1,c=i.child;c;){if(c===n){o=!0,n=i,r=a;break}if(c===r){o=!0,r=i,n=a;break}c=c.sibling}if(!o){for(c=a.child;c;){if(c===n){o=!0,n=a,r=i;break}if(c===r){o=!0,r=a,n=i;break}c=c.sibling}if(!o)throw Error(s(189))}}if(n.alternate!==r)throw Error(s(190))}if(n.tag!==3)throw Error(s(188));return n.stateNode.current===n?e:t}function m(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=m(e),t!==null)return t;e=e.sibling}return null}function h(e,t,n,r,i,a){for(;e!==null;){if((e.tag===5||e.tag===27||e.tag===6)&&n(e,r,i,a)||(e.tag!==22||e.memoizedState===null)&&(t||e.tag!==5&&e.tag!==27)&&h(e.child,t,n,r,i,a))return!0;e=e.sibling}return!1}function g(e){for(e=e.return;e!==null;){if(e.tag===3||e.tag===5||e.tag===27)return e;e=e.return}return null}function _(e){var t=!1;for(e=e.return;e!==null&&(e.tag===4&&(t=!0),e.tag!==3&&e.tag!==5&&e.tag!==27);)e=e.return;return t}function v(e){var t=[null,null],n=g(e);return n===null||y(t,e,n.child,{foundSelf:!1}),t}function y(e,t,n,r){for(;n!==null;){if(n===t)r.foundSelf=!0;else if(n.tag===5||n.tag===27||n.tag===6){if(r.foundSelf)return e[1]=n,!0;e[0]=n}else if((n.tag!==22||n.memoizedState===null)&&y(e,t,n.child,r))return!0;n=n.sibling}return!1}function b(e){switch(e.tag){case 5:case 27:case 6:return e.stateNode;case 3:return e.stateNode.containerInfo;default:throw Error(s(559))}}var ee=null,te=null;function ne(e,t,n){return e===n||e===t&&(ee=e,!0)}function re(e,t,n){return e===n?(te=e,!1):e===t&&(te!==null&&(ee=e),!0)}function x(e){if(e===null)return null;do e=e===null?null:e.return;while(e&&e.tag!==5&&e.tag!==27&&e.tag!==3);return e||null}function ie(e,t,n){for(var r=0,i=e;i;i=n(i))r++;i=0;for(var a=t;a;a=n(a))i++;for(;0<r-i;)e=n(e),r--;for(;0<i-r;)t=n(t),i--;for(;r--;){if(e===t||t!==null&&e===t.alternate)return e;e=n(e),t=n(t)}return null}var S=Object.assign,ae=Symbol.for(`react.element`),oe=Symbol.for(`react.transitional.element`),se=Symbol.for(`react.portal`),ce=Symbol.for(`react.fragment`),le=Symbol.for(`react.strict_mode`),ue=Symbol.for(`react.profiler`),de=Symbol.for(`react.consumer`),fe=Symbol.for(`react.context`),pe=Symbol.for(`react.forward_ref`),me=Symbol.for(`react.suspense`),he=Symbol.for(`react.suspense_list`),ge=Symbol.for(`react.memo`),_e=Symbol.for(`react.lazy`),ve=Symbol.for(`react.activity`),ye=Symbol.for(`react.legacy_hidden`),be=Symbol.for(`react.memo_cache_sentinel`),xe=Symbol.for(`react.view_transition`),Se=Symbol.for(`react.recoverable`),Ce=Symbol.iterator;function we(e){return typeof e!=`object`||!e?null:(e=Ce&&e[Ce]||e[`@@iterator`],typeof e==`function`?e:null)}var Te=Symbol.for(`react.client.reference`);function Ee(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===Te?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case ce:return`Fragment`;case ue:return`Profiler`;case le:return`StrictMode`;case me:return`Suspense`;case he:return`SuspenseList`;case ve:return`Activity`;case xe:return`ViewTransition`}if(typeof e==`object`)switch(e.$$typeof){case se:return`Portal`;case fe:return e.displayName||`Context`;case de:return(e._context.displayName||`Context`)+`.Consumer`;case pe:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case ge:return t=e.displayName||null,t===null?Ee(e.type)||`Memo`:t;case _e:t=e._payload,e=e._init;try{return Ee(e(t))}catch{}}return null}var De=Array.isArray,C=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,w=a.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Oe={pending:!1,data:null,method:null,action:null},ke=[],Ae=-1;function je(e){return{current:e}}function Me(e){0>Ae||(e.current=ke[Ae],ke[Ae]=null,Ae--)}function T(e,t){Ae++,ke[Ae]=e.current,e.current=t}var Ne=je(null),Pe=je(null),Fe=je(null),Ie=je(null);function Le(e,t){switch(T(Fe,t),T(Pe,e),T(Ne,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?up(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=up(t),e=dp(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}Me(Ne),T(Ne,e)}function Re(){Me(Ne),Me(Pe),Me(Fe)}function ze(e){var t=e.memoizedState;t!==null&&(sh._currentValue=t.memoizedState,T(Ie,e)),t=Ne.current;var n=dp(t,e.type);t!==n&&(T(Pe,e),T(Ne,n))}function Be(e){Pe.current===e&&(Me(Ne),Me(Pe)),Ie.current===e&&(Me(Ie),sh._currentValue=Oe)}var Ve,He;function Ue(e){if(Ve===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);Ve=t&&t[1]||``,He=-1<e.stack.indexOf(`
|
|
1
|
+
import{t as e}from"./rolldown-runtime-hePW80VL.js";var t=e((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.for(`react.view_transition`),m=Symbol.iterator;function h(e){return typeof e!=`object`||!e?null:(e=m&&e[m]||e[`@@iterator`],typeof e==`function`?e:null)}var g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,v={};function y(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}y.prototype.isReactComponent={},y.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function b(){}b.prototype=y.prototype;function ee(e,t,n){this.props=e,this.context=t,this.refs=v,this.updater=n||g}var te=ee.prototype=new b;te.constructor=ee,_(te,y.prototype),te.isPureReactComponent=!0;var ne=Array.isArray;function re(){}var x={H:null,A:null,T:null,S:null},ie=Object.prototype.hasOwnProperty;function S(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function ae(e,t){return S(e.type,t,e.props)}function oe(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function se(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var ce=/\/+/g;function le(e,t){return typeof e==`object`&&e&&e.key!=null?se(``+e.key):t.toString(36)}function ue(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(re,re):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function de(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,de(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+le(e,0):a,ne(o)?(i=``,c!=null&&(i=c.replace(ce,`$&/`)+`/`),de(o,r,i,``,function(e){return e})):o!=null&&(oe(o)&&(o=ae(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(ce,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(ne(e))for(var u=0;u<e.length;u++)a=e[u],s=l+le(a,u),c+=de(a,r,i,s,o);else if(u=h(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+le(a,u++),c+=de(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return de(ue(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function fe(e,t,n){if(e==null)return e;var r=[],i=0;return de(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function pe(e){if(e._status===-1){var t=e._result,n=t();n.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t,n.status===void 0&&(n.status=`fulfilled`,n.value=t))},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t,n.status===void 0&&(n.status=`rejected`,n.reason=t))}),e._status===-1&&(e._status=0,e._result=n)}if(e._status===1)return e._result.default;throw e._result}var me=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)};function he(e){var t=x.T,n={};n.types=t===null?null:t.types,x.T=n;try{var r=e(),i=x.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(re,me)}catch(e){me(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),x.T=t}}function ge(e){var t=x.T;if(t!==null){var n=t.types;n===null?t.types=[e]:n.indexOf(e)===-1&&n.push(e)}else he(ge.bind(null,e))}var _e={map:fe,forEach:function(e,t,n){fe(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return fe(e,function(){t++}),t},toArray:function(e){return fe(e,function(e){return e})||[]},only:function(e){if(!oe(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=_e,e.Component=y,e.Fragment=r,e.Profiler=a,e.PureComponent=ee,e.StrictMode=i,e.Suspense=l,e.ViewTransition=p,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=x,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return x.H.useMemoCache(e)}},e.addTransitionType=ge,e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=_({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!ie.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return S(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)ie.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return S(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=oe,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:pe}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=he,e.unstable_useCacheRefresh=function(){return x.H.useCacheRefresh()},e.use=function(e){return x.H.use(e)},e.useActionState=function(e,t,n){return x.H.useActionState(e,t,n)},e.useCallback=function(e,t){return x.H.useCallback(e,t)},e.useContext=function(e){return x.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return x.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return x.H.useEffect(e,t)},e.useEffectEvent=function(e){return x.H.useEffectEvent(e)},e.useId=function(){return x.H.useId()},e.useImperativeHandle=function(e,t,n){return x.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return x.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return x.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return x.H.useMemo(e,t)},e.useOptimistic=function(e,t){return x.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return x.H.useReducer(e,t,n)},e.useRef=function(e){return x.H.useRef(e)},e.useState=function(e){return x.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return x.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return x.H.useTransition()},e.version=`19.3.1`})),n=e(((e,n)=>{n.exports=t()})),r=e((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function ee(e){if(h=!1,b(e),!m){if(n(c)!==null)m=!0,te||(te=!0,ae());else{var t=n(l);t!==null&&ce(ee,t.startTime-e)}}}var te=!1,ne=-1,re=5,x=-1;function ie(){return g?!0:!(e.unstable_now()-x<re)}function S(){if(g=!1,te){var t=e.unstable_now();x=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(ne),ne=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&ie());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&ce(ee,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?ae():te=!1}}}var ae;if(typeof y==`function`)ae=function(){y(S)};else if(typeof MessageChannel<`u`){var oe=new MessageChannel,se=oe.port2;oe.port1.onmessage=S,ae=function(){se.postMessage(null)}}else ae=function(){_(S,0)};function ce(t,n){ne=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):re=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(ne),ne=-1):h=!0,ce(ee,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,te||(te=!0,ae()))),r},e.unstable_shouldYield=ie,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),i=e(((e,t)=>{t.exports=r()})),a=e((e=>{var t=n();function r(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function i(){}var a={d:{f:i,r:function(){throw Error(r(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},o=Symbol.for(`react.portal`),s=Symbol.for(`react.recoverable`),c=Symbol.for(`react.optimistic_key`);function l(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:r==null?null:r===c?c:``+r,children:e,containerInfo:t,implementation:n}}var u=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function d(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=a,e.browser=function(e){return{$$typeof:s,_reason:e}},e.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(r(299));return l(e,t,null,n)},e.flushSync=function(e){var t=u.T,n=a.p;try{if(u.T=null,a.p=2,e)return e()}finally{u.T=t,a.p=n,a.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,a.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&a.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=d(n,t.crossOrigin),i=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?a.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:i,fetchPriority:o}):n===`script`&&a.d.X(e,{crossOrigin:r,integrity:i,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`){if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=d(t.as,t.crossOrigin);a.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0})}}else t??a.d.M(e)}},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=d(n,t.crossOrigin);a.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`){if(t){var n=d(t.as,t.crossOrigin);a.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0})}else a.d.m(e)}},e.requestFormReset=function(e){a.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return u.H.useFormState(e,t,n)},e.useFormStatus=function(){return u.H.useHostTransitionStatus()},e.version=`19.3.1`})),o=e(((e,t)=>{function n(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE==`function`)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=a()})),s=e((e=>{var t=i(),r=n(),a=o();function s(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function c(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function l(e){for(var t=e,n=t;n&&!n.alternate;)t=n,t.flags&4098&&(e=t.return),n=t.return;for(;t.return;)t=t.return;return t.tag===3?e:null}function u(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function d(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function f(e){if(l(e)!==e)throw Error(s(188))}function p(e){var t=e.alternate;if(!t){if(t=l(e),t===null)throw Error(s(188));return t===e?e:null}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var a=i.alternate;if(a===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===n)return f(i),e;if(a===r)return f(i),t;a=a.sibling}throw Error(s(188))}if(n.return!==r.return)n=i,r=a;else{for(var o=!1,c=i.child;c;){if(c===n){o=!0,n=i,r=a;break}if(c===r){o=!0,r=i,n=a;break}c=c.sibling}if(!o){for(c=a.child;c;){if(c===n){o=!0,n=a,r=i;break}if(c===r){o=!0,r=a,n=i;break}c=c.sibling}if(!o)throw Error(s(189))}}if(n.alternate!==r)throw Error(s(190))}if(n.tag!==3)throw Error(s(188));return n.stateNode.current===n?e:t}function m(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=m(e),t!==null)return t;e=e.sibling}return null}function h(e,t,n,r,i,a){for(;e!==null;){if((e.tag===5||e.tag===27||e.tag===6)&&n(e,r,i,a)||(e.tag!==22||e.memoizedState===null)&&(t||e.tag!==5&&e.tag!==27)&&h(e.child,t,n,r,i,a))return!0;e=e.sibling}return!1}function g(e){for(e=e.return;e!==null;){if(e.tag===3||e.tag===5||e.tag===27)return e;e=e.return}return null}function _(e){var t=!1;for(e=e.return;e!==null&&(e.tag===4&&(t=!0),e.tag!==3&&e.tag!==5&&e.tag!==27);)e=e.return;return t}function v(e){var t=[null,null],n=g(e);return n===null||y(t,e,n.child,{foundSelf:!1}),t}function y(e,t,n,r){for(;n!==null;){if(n===t)r.foundSelf=!0;else if(n.tag===5||n.tag===27||n.tag===6){if(r.foundSelf)return e[1]=n,!0;e[0]=n}else if((n.tag!==22||n.memoizedState===null)&&y(e,t,n.child,r))return!0;n=n.sibling}return!1}function b(e){switch(e.tag){case 5:case 27:case 6:return e.stateNode;case 3:return e.stateNode.containerInfo;default:throw Error(s(559))}}var ee=null,te=null;function ne(e,t,n){return e===n||e===t&&(ee=e,!0)}function re(e,t,n){return e===n?(te=e,!1):e===t&&(te!==null&&(ee=e),!0)}function x(e){if(e===null)return null;do e=e===null?null:e.return;while(e&&e.tag!==5&&e.tag!==27&&e.tag!==3);return e||null}function ie(e,t,n){for(var r=0,i=e;i;i=n(i))r++;i=0;for(var a=t;a;a=n(a))i++;for(;0<r-i;)e=n(e),r--;for(;0<i-r;)t=n(t),i--;for(;r--;){if(e===t||t!==null&&e===t.alternate)return e;e=n(e),t=n(t)}return null}var S=Object.assign,ae=Symbol.for(`react.element`),oe=Symbol.for(`react.transitional.element`),se=Symbol.for(`react.portal`),ce=Symbol.for(`react.fragment`),le=Symbol.for(`react.strict_mode`),ue=Symbol.for(`react.profiler`),de=Symbol.for(`react.consumer`),fe=Symbol.for(`react.context`),pe=Symbol.for(`react.forward_ref`),me=Symbol.for(`react.suspense`),he=Symbol.for(`react.suspense_list`),ge=Symbol.for(`react.memo`),_e=Symbol.for(`react.lazy`),ve=Symbol.for(`react.activity`),ye=Symbol.for(`react.legacy_hidden`),be=Symbol.for(`react.memo_cache_sentinel`),xe=Symbol.for(`react.view_transition`),Se=Symbol.for(`react.recoverable`),Ce=Symbol.iterator;function we(e){return typeof e!=`object`||!e?null:(e=Ce&&e[Ce]||e[`@@iterator`],typeof e==`function`?e:null)}var Te=Symbol.for(`react.client.reference`);function Ee(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===Te?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case ce:return`Fragment`;case ue:return`Profiler`;case le:return`StrictMode`;case me:return`Suspense`;case he:return`SuspenseList`;case ve:return`Activity`;case xe:return`ViewTransition`}if(typeof e==`object`)switch(e.$$typeof){case se:return`Portal`;case fe:return e.displayName||`Context`;case de:return(e._context.displayName||`Context`)+`.Consumer`;case pe:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case ge:return t=e.displayName||null,t===null?Ee(e.type)||`Memo`:t;case _e:t=e._payload,e=e._init;try{return Ee(e(t))}catch{}}return null}var De=Array.isArray,C=r.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,w=a.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Oe={pending:!1,data:null,method:null,action:null},ke=[],Ae=-1;function je(e){return{current:e}}function Me(e){0>Ae||(e.current=ke[Ae],ke[Ae]=null,Ae--)}function T(e,t){Ae++,ke[Ae]=e.current,e.current=t}var Ne=je(null),Pe=je(null),Fe=je(null),Ie=je(null);function Le(e,t){switch(T(Fe,t),T(Pe,e),T(Ne,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?up(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=up(t),e=dp(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}Me(Ne),T(Ne,e)}function Re(){Me(Ne),Me(Pe),Me(Fe)}function ze(e){var t=e.memoizedState;t!==null&&(sh._currentValue=t.memoizedState,T(Ie,e)),t=Ne.current;var n=dp(t,e.type);t!==n&&(T(Pe,e),T(Ne,n))}function Be(e){Pe.current===e&&(Me(Ne),Me(Pe)),Ie.current===e&&(Me(Ie),sh._currentValue=Oe)}var Ve,He;function Ue(e){if(Ve===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);Ve=t&&t[1]||``,He=-1<e.stack.indexOf(`
|
|
2
2
|
at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return`
|
|
3
3
|
`+Ve+e+He}var We=!1;function Ge(e,t){if(!e||We)return``;We=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}n=!1;try{var i=Object.getOwnPropertyDescriptor(e.prototype,`props`);Object.defineProperty(e.prototype,"props",{configurable:!0,set:function(){throw Error()}}),n=!0,new e}finally{n&&(i===void 0?delete e.prototype.props:Object.defineProperty(e.prototype,"props",i))}}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(`
|
|
4
4
|
`),l=s.split(`
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,n)=>{let r={};for(var i in e)t(r,i,{get:e[i],enumerable:!0});return n||t(r,Symbol.toStringTag,{value:`Module`}),r},c=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},l=(n,r,o)=>(o=n==null?{}:e(i(n)),c(r||!n||!n.__esModule||!a.call(n,`default`)?t(o,`default`,{value:n,enumerable:!0}):o,n));export{s as n,l as r,o as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e={agents:{label:`Agents`,type:`agent`,desc:`capability specialists`,icon:`agent`},skills:{label:`Skills`,type:`skill`,desc:`repeatable workflows`,icon:`skill`},laws:{label:`Constitution`,type:`law`,desc:`ontology, dictates, doctrines`,icon:`law`},memory:{label:`Memory`,type:`memory`,desc:`durable facts`,icon:`library`},notebook:{label:`Notebook`,type:`notebook`,desc:`sovereign space`,icon:`notebook`},wiki:{label:`Wiki`,type:`wiki`,desc:`knowledge base`,icon:`graph`},config:{label:`Setup files`,type:`config`,desc:`install metadata`,icon:`settings`}},t=[`agents`,`memory`,`notebook`,`wiki`,`config`],n=[`skills`,`agents`,`memory`,`notebook`,`wiki`,`config`],r=Object.fromEntries(Object.entries(e).map(([e,t])=>[t.type,e]));export{r as i,e as n,t as r,n as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{i as t}from"./react-DlYQp10C.js";var n=e(t(),1);function r(e,t,r){(0,n.useEffect)(()=>{let n=!0,r=()=>n,i=()=>{document.hidden||e(r)};e(r);let a=setInterval(i,t);return document.addEventListener(`visibilitychange`,i),()=>{n=!1,clearInterval(a),document.removeEventListener(`visibilitychange`,i)}},r)}export{r as t};
|
package/web/dist/index.html
CHANGED
|
@@ -11,11 +11,12 @@
|
|
|
11
11
|
<!-- The brand sprout as an inline SVG favicon (no extra asset to serve). -->
|
|
12
12
|
<link rel="icon" type="image/svg+xml"
|
|
13
13
|
href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21.5v-9' stroke='%233AD4C4' stroke-width='2' stroke-linecap='round' fill='none'/%3E%3Cpath d='M12 13c0-4.5 3.2-7.5 7.5-7.5 0 4.5-3.2 7.5-7.5 7.5z' fill='%233AD4C4'/%3E%3Cpath d='M12 14.5c0-3.6-2.6-6-6-6 0 3.6 2.6 6 6 6z' fill='%233AD4C4' opacity='.42'/%3E%3C/svg%3E" />
|
|
14
|
-
<script type="module" crossorigin src="/assets/index-
|
|
15
|
-
<link rel="modulepreload" crossorigin href="/assets/
|
|
16
|
-
<link rel="modulepreload" crossorigin href="/assets/react-
|
|
17
|
-
<link rel="modulepreload" crossorigin href="/assets/api-
|
|
18
|
-
<link rel="
|
|
14
|
+
<script type="module" crossorigin src="/assets/index-C9R_bRw_.js"></script>
|
|
15
|
+
<link rel="modulepreload" crossorigin href="/assets/rolldown-runtime-hePW80VL.js">
|
|
16
|
+
<link rel="modulepreload" crossorigin href="/assets/react-DlYQp10C.js">
|
|
17
|
+
<link rel="modulepreload" crossorigin href="/assets/api-BfpZmUMI.js">
|
|
18
|
+
<link rel="modulepreload" crossorigin href="/assets/sections-ChwaobfW.js">
|
|
19
|
+
<link rel="stylesheet" crossorigin href="/assets/index-jYlWihN-.css">
|
|
19
20
|
</head>
|
|
20
21
|
<body>
|
|
21
22
|
<div id="root"></div>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{C as i,N as a,Q as o,R as s,x as c}from"./index-DQXG_mqo.js";import{a as l,i as u,n as d,o as f,r as p,t as m}from"./activity-DvPxoS4Y.js";import{t as h}from"./usePoll-NSTzLOF4.js";var g=e(t(),1),_=n();function v({s:e}){let t=p[e.status]||p.idle,n=e.files,r=e.todos,i=r&&r.total>0||e.error||e.blocked_on;return(0,_.jsxs)(`a`,{className:`card pad-md act-card`,href:`#/activity/${encodeURIComponent(e.session_id)}`,children:[(0,_.jsxs)(`div`,{className:`row between wrap gap-12`,children:[(0,_.jsxs)(`div`,{className:`row gap-10`,style:{minWidth:0},children:[(0,_.jsx)(`span`,{className:`feed-dot ${t.cls||`acc`}`,style:{width:9,height:9}}),(0,_.jsxs)(`div`,{style:{minWidth:0},children:[(0,_.jsx)(`h3`,{style:{margin:0},children:e.title||l(e.cwd)||e.session_id}),e.cwd&&(0,_.jsx)(`div`,{className:`dim mono`,style:{fontSize:12,...m},title:e.cwd,children:e.cwd})]})]}),(0,_.jsxs)(`div`,{className:`row gap-8`,style:{flexShrink:0},children:[e.model&&(0,_.jsx)(`span`,{className:`badge mono`,title:`model`,children:e.model}),e.agent&&(0,_.jsx)(`span`,{className:`badge`,children:e.agent}),(0,_.jsxs)(`span`,{className:`badge ${t.cls}`,children:[(0,_.jsx)(`span`,{className:`dot`}),t.label]}),(0,_.jsx)(a,{name:`chevron`,className:`glyph act-chev`})]})]}),e.phase&&(0,_.jsxs)(`div`,{className:`row gap-8`,style:{marginTop:10,fontSize:14},children:[(0,_.jsx)(a,{name:`activity`}),(0,_.jsx)(`span`,{style:m,children:e.phase})]}),(e.tokens>0||e.cost>0||e.turn_started_at||n&&n.count>0)&&(0,_.jsxs)(`div`,{className:`row wrap`,style:{gap:16,marginTop:12,fontSize:13,color:`var(--text-2)`},children:[e.tokens>0&&(0,_.jsxs)(`span`,{children:[f(e.tokens),` tok`]}),e.cost>0&&(0,_.jsxs)(`span`,{children:[`$`,e.cost.toFixed(2)]}),e.turn_started_at?(0,_.jsx)(`span`,{children:(0,_.jsx)(d,{startedAt:e.turn_started_at})}):null,n&&n.count>0&&(0,_.jsxs)(`span`,{children:[n.count,` file`,n.count===1?``:`s`,` `,(0,_.jsxs)(`span`,{style:{color:`var(--good)`},children:[`+`,n.additions]}),` `,(0,_.jsxs)(`span`,{style:{color:`var(--bad)`},children:[`−`,n.deletions]})]})]}),i&&(0,_.jsxs)(`div`,{className:`row between wrap gap-12`,style:{marginTop:12,paddingTop:10,borderTop:`1px solid var(--line)`},children:[r&&r.total>0?(0,_.jsxs)(`span`,{className:`row gap-8 dim`,style:{fontSize:13},children:[(0,_.jsx)(u,{done:r.done,total:r.total}),`plan `,r.done,`/`,r.total]}):(0,_.jsx)(`span`,{}),e.error?(0,_.jsx)(`span`,{className:`badge bad`,title:e.error,style:{maxWidth:300,...m},children:e.error}):e.blocked_on?(0,_.jsx)(`span`,{className:`badge bad`,title:e.blocked_on,style:{maxWidth:300,...m},children:e.blocked_on}):null]}),(0,_.jsxs)(`div`,{className:`dim mono`,style:{fontSize:11,marginTop:8},children:[`updated `,s(e.updated_at),` ago`]})]})}function y(){let[e,t]=(0,g.useState)(null),[n,a]=(0,g.useState)(``);h(e=>r.activity().then(n=>{e()&&(t(n),a(``))},t=>{e()&&a(t.message)}),2e3,[]);let s=!e||e.enabled!==!1,l=e?.activity||[],u=o(),d=async()=>{let e=!s;try{let n=await r.activityToggle(e);t(e=>({...e||{},enabled:n.enabled,activity:n.enabled&&e?.activity||[]})),a(``)}catch(e){a(e.message)}};return(0,_.jsxs)(`div`,{className:`narrow`,children:[(0,_.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`h1`,{className:`h`,children:`Activity`}),(0,_.jsx)(`p`,{className:`sub`,children:`Live OpenCode sessions this harness is running: what each one is doing right now. Refreshes every couple of seconds; sessions drop off when their process exits.`})]}),(0,_.jsxs)(`div`,{className:`row gap-10`,style:{alignItems:`center`,flexShrink:0},children:[(0,_.jsx)(`span`,{className:`dim mono`,style:{fontSize:12},children:s?`tracking on`:`tracking off`}),(0,_.jsx)(`div`,{className:`sw-toggle${s?` on`:``}`,role:`switch`,"aria-checked":s,"aria-label":`Toggle activity tracking`,tabIndex:0,onClick:d,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.key===` `&&e.preventDefault(),d())}})]})]}),(0,_.jsx)(c,{error:n,style:{marginBottom:12}}),e?s?l.length===0?(0,_.jsxs)(`div`,{className:`empty`,children:[(0,_.jsx)(`div`,{className:`big`,children:`No active sessions`}),`Run `,(0,_.jsx)(`code`,{children:`opencode`}),` and the sessions it spins up appear here.`]}):(0,_.jsx)(`div`,{className:`stack gap-12`,ref:u,children:l.map(e=>(0,_.jsx)(`div`,{"data-flip":e.session_id,children:(0,_.jsx)(v,{s:e})},e.session_id))}):(0,_.jsxs)(`div`,{className:`empty`,children:[(0,_.jsx)(`div`,{className:`big`,children:`Activity tracking is off`}),`The plugin isn't recording sessions. Flip the switch to turn it back on.`]}):(0,_.jsx)(i,{label:`Reading live sessions…`})]})}export{y as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{C as i,N as a,R as o}from"./index-DQXG_mqo.js";import{a as s,n as c,o as l,r as u,t as d}from"./activity-DvPxoS4Y.js";import{t as f}from"./usePoll-NSTzLOF4.js";var p=e(t(),1),m=n();function h(e){return e.kind===`tool`?e.status===`error`?`bad`:e.status===`completed`?`ok`:`acc`:{retry:`warn`,error:`bad`,subtask:`acc`,text:`acc`}[e.kind]||``}function g({rec:e}){let t=e.who===`you`,n=[];t||(e.kind===`tool`&&e.ms!=null&&n.push(`${(e.ms/1e3).toFixed(1)}s`),e.kind===`step`&&(e.tokens&&n.push(`${l(e.tokens)} tok`),e.cost&&n.push(`$${e.cost.toFixed(2)}`)),e.kind===`subtask`&&e.agent&&n.unshift(e.agent));let r=!t&&(e.kind===`text`||e.kind===`thinking`||e.kind===`step`),i=t?e.text:e.label||e.snippet||e.kind;return(0,m.jsxs)(`div`,{className:`row gap-10`,style:{alignItems:`baseline`},children:[(0,m.jsx)(`span`,{className:`badge ${t?``:`acc`}`,style:{flexShrink:0,minWidth:52,justifyContent:`center`},children:t?`you`:`agent`}),(0,m.jsxs)(`div`,{style:{minWidth:0,flex:1,fontSize:13},children:[!t&&(0,m.jsx)(`span`,{className:`feed-dot ${h(e)||`acc`}`,style:{display:`inline-block`,marginRight:8,verticalAlign:`middle`}}),e.kind===`thinking`&&(0,m.jsx)(`span`,{className:`dim`,children:`thinking: `}),r?(0,m.jsx)(`span`,{className:`dim`,children:i}):t?i:(0,m.jsx)(`b`,{children:i}),e.error&&(0,m.jsxs)(`span`,{className:`dim`,children:[`: `,e.error]})]}),n.length>0&&(0,m.jsx)(`span`,{className:`dim mono`,style:{flexShrink:0,fontSize:12},children:n.join(` · `)})]})}function _({turns:e}){return!e||e.length===0?(0,m.jsx)(`div`,{className:`dim`,style:{fontSize:13},children:`No conversation captured yet.`}):(0,m.jsx)(`div`,{className:`stack gap-12`,children:e.map((e,t)=>{let n=e.role===`user`;return(0,m.jsxs)(`div`,{className:`row gap-10`,style:{alignItems:`baseline`},children:[(0,m.jsx)(`span`,{className:`badge ${n?``:`acc`}`,style:{flexShrink:0,minWidth:52,justifyContent:`center`},children:n?`you`:`agent`}),(0,m.jsx)(`div`,{style:{minWidth:0,fontSize:13,color:n?`inherit`:`var(--text-2)`},children:e.text})]},t)})})}function v({sid:e}){let[t,n]=(0,p.useState)(null),[h,v]=(0,p.useState)(``),[y,b]=(0,p.useState)(!1),[x,S]=(0,p.useState)(!1);f(t=>r.activityDetail(e).then(e=>{t()&&(n(e),v(``),b(!1))},e=>{t()&&(e.status===404?b(!0):v(e.message))}),2e3,[e]);let C=(0,m.jsxs)(`a`,{className:`btn ghost sm`,href:`#/activity`,style:{marginBottom:12,display:`inline-flex`,gap:6},children:[(0,m.jsx)(a,{name:`arrow`,style:{transform:`rotate(180deg)`}}),` Activity`]});if(y)return(0,m.jsxs)(`div`,{className:`narrow`,children:[C,(0,m.jsxs)(`div`,{className:`empty`,children:[(0,m.jsx)(`div`,{className:`big`,children:`Session ended`}),`It's no longer live. `,(0,m.jsx)(`a`,{href:`#/activity`,children:`Back to Activity`}),`.`]})]});if(!t)return(0,m.jsxs)(`div`,{className:`narrow`,children:[C,(0,m.jsx)(i,{label:`Loading session…`})]});let w=t.session,T=u[w.status]||u.idle,E=w.files,D=w.todos,O=!!(E&&E.items&&E.items.length>0),k=!!(D&&D.items&&D.items.length>0),A=t.conversation||[],j=t.timeline||[],M=[...A.filter(e=>e.role===`user`).map(e=>({who:`you`,text:e.text,t:e.t||0})),...j.map(e=>({...e,who:`agent`}))].sort((e,t)=>(e.t||0)-(t.t||0));return(0,m.jsxs)(`div`,{className:`narrow`,children:[C,h&&(0,m.jsx)(`p`,{className:`badge bad`,style:{marginBottom:12},children:h}),(0,m.jsxs)(`div`,{className:`card pad-md`,children:[(0,m.jsxs)(`div`,{className:`row between wrap gap-12`,children:[(0,m.jsxs)(`div`,{style:{minWidth:0},children:[(0,m.jsx)(`h1`,{className:`h`,style:{margin:0},children:w.title||s(w.cwd)||w.session_id}),w.cwd&&(0,m.jsx)(`div`,{className:`dim mono`,style:{fontSize:12,...d},title:w.cwd,children:w.cwd})]}),(0,m.jsxs)(`div`,{className:`row gap-8`,style:{flexShrink:0},children:[w.model&&(0,m.jsx)(`span`,{className:`badge mono`,children:w.model}),w.agent&&(0,m.jsx)(`span`,{className:`badge`,children:w.agent}),(0,m.jsxs)(`span`,{className:`badge ${T.cls}`,children:[(0,m.jsx)(`span`,{className:`dot`}),T.label]})]})]}),w.phase&&(0,m.jsxs)(`div`,{className:`row gap-8`,style:{marginTop:10,fontSize:14},children:[(0,m.jsx)(a,{name:`activity`}),(0,m.jsx)(`span`,{style:d,children:w.phase})]}),(0,m.jsxs)(`div`,{className:`row wrap`,style:{gap:16,marginTop:12,fontSize:13,color:`var(--text-2)`},children:[w.tokens>0&&(0,m.jsxs)(`span`,{children:[l(w.tokens),` tok`]}),w.cost>0&&(0,m.jsxs)(`span`,{children:[`$`,w.cost.toFixed(2)]}),w.turn_started_at?(0,m.jsx)(`span`,{children:(0,m.jsx)(c,{startedAt:w.turn_started_at})}):null,(0,m.jsxs)(`span`,{className:`dim`,children:[`updated `,o(w.updated_at),` ago`]})]}),(w.error||w.blocked_on)&&(0,m.jsx)(`div`,{style:{marginTop:10},children:(0,m.jsx)(`span`,{className:`badge bad`,style:{maxWidth:`100%`,...d},children:w.error||w.blocked_on})})]}),(O||k)&&(0,m.jsxs)(`div`,{className:`grid gap-12`,style:{marginTop:12,gridTemplateColumns:O&&k?`minmax(0, 1fr) minmax(0, 1fr)`:`1fr`},children:[O&&(0,m.jsxs)(`div`,{className:`card pad-md`,children:[(0,m.jsx)(`div`,{className:`card-head`,children:(0,m.jsxs)(`h3`,{children:[`Files touched `,(0,m.jsxs)(`span`,{className:`dim`,children:[`(`,E.count,`)`]})]})}),(0,m.jsx)(`div`,{className:`stack`,style:{gap:6,marginTop:8},children:E.items.map(e=>(0,m.jsxs)(`div`,{className:`row between gap-12`,style:{fontSize:13},children:[(0,m.jsx)(`span`,{className:`mono`,style:{...d,minWidth:0,flex:1},title:e.file,children:e.file}),(0,m.jsxs)(`span`,{style:{flexShrink:0},children:[(0,m.jsxs)(`span`,{style:{color:`var(--good)`},children:[`+`,e.additions]}),` `,(0,m.jsxs)(`span`,{style:{color:`var(--bad)`},children:[`−`,e.deletions]})]})]},e.file))})]}),k&&(0,m.jsxs)(`div`,{className:`card pad-md`,children:[(0,m.jsx)(`div`,{className:`card-head`,children:(0,m.jsxs)(`h3`,{children:[`Plan`,` `,(0,m.jsxs)(`span`,{className:`dim`,children:[`(`,D.done,`/`,D.total,`)`]})]})}),(0,m.jsx)(`div`,{className:`stack`,style:{gap:6,marginTop:8},children:D.items.map((e,t)=>(0,m.jsxs)(`div`,{className:`row gap-8`,style:{fontSize:13},children:[(0,m.jsx)(`span`,{className:`feed-dot ${e.status===`completed`?`ok`:e.status===`in_progress`?`acc`:``}`}),(0,m.jsx)(`span`,{style:{textDecoration:e.status===`completed`?`line-through`:`none`,color:e.status===`completed`?`var(--text-3)`:`inherit`},children:e.content})]},t))})]})]}),(0,m.jsxs)(`div`,{className:`card pad-md`,style:{marginTop:12},children:[(0,m.jsxs)(`div`,{className:`card-head`,style:{justifyContent:`space-between`,marginBottom:12},children:[(0,m.jsx)(`h3`,{children:`Timeline`}),j.length>0&&(0,m.jsx)(`button`,{className:`btn ghost sm`,onClick:()=>S(e=>!e),children:x?`Show conversation`:`Show all ${j.length} steps`})]}),x?(0,m.jsx)(`div`,{className:`stack gap-12`,children:M.map((e,t)=>(0,m.jsx)(g,{rec:e},t))}):(0,m.jsx)(_,{turns:A})]})]})}export{v as default};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/GreenhouseView-zk2Uzc3A.js","assets/sections-BET3c1WT.js","assets/react-BOF6yL40.js","assets/drawable-CyLe1gtW.js","assets/index-DQXG_mqo.js","assets/api-CiXlkbe0.js","assets/index-BCJz4_8C.css","assets/jobBuckets-Dbq8ZlWW.js","assets/OperatorHudView-CyiGhiHk.js","assets/JournalView-Bfj27XHC.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{n as e,o as t,r as n,s as r}from"./sections-BET3c1WT.js";import{i,t as a}from"./react-BOF6yL40.js";import{t as o}from"./api-CiXlkbe0.js";import{B as s,C as c,F as l,I as u,J as d,L as f,N as p,R as m,T as h,V as g,Z as _,b as v,q as y,t as b,x}from"./index-DQXG_mqo.js";var S=r(i(),1),C={neutral:`Loaded & ready`,imperial:`The Codex in force`,military:`The unit stands ready`,cyberpunk:`Jacked in`,wizard:`Wards in place`,pirate:`The crew stands ready`,gamer:`Game loaded`,sports:`The squad takes the field`,biker:`The crew rolls out`,commentator:`Lights out, away we go`,verstappen:`Setup's in`,joker:`Mic check`,mean:`Rules are up`,marvin:`Online. Reluctantly.`},w=e=>e.deployed?C[e.theme]||`Loaded & ready`:`Not deployed`,T=a();function E({value:e,size:t=232}){let n=_(e,1100)??0,r=t/2-14,i=2*Math.PI*r,a=i*(1-n);return(0,T.jsxs)(`div`,{className:`ring-wrap`,style:{width:t,height:t},children:[(0,T.jsxs)(`svg`,{viewBox:`0 0 ${t} ${t}`,children:[(0,T.jsx)(`circle`,{cx:t/2,cy:t/2,r,fill:`none`,stroke:`var(--surface-3)`,strokeWidth:`10`}),(0,T.jsx)(`circle`,{cx:t/2,cy:t/2,r,fill:`none`,stroke:`var(--accent)`,strokeWidth:`10`,strokeLinecap:`round`,strokeDasharray:i,strokeDashoffset:a}),Array.from({length:48}).map((e,i)=>{let a=i/48*2*Math.PI,o=r-18,s=r-24,c=t/2+Math.cos(a)*o,l=t/2+Math.sin(a)*o,u=t/2+Math.cos(a)*s,d=t/2+Math.sin(a)*s;return(0,T.jsx)(`line`,{x1:c,y1:l,x2:u,y2:d,stroke:`var(--line-2)`,strokeWidth:`1`,opacity:i/48<n?.9:.25},i)})]}),(0,T.jsxs)(`div`,{className:`ring-center`,children:[(0,T.jsxs)(`div`,{className:`pct`,children:[Math.round(n*100),(0,T.jsx)(`span`,{style:{fontSize:20,color:`var(--text-3)`},children:`%`})]}),(0,T.jsx)(`div`,{className:`lbl`,children:`germination`})]})]})}function D({overview:e}){let t=l(e.diff),n=e.counts||{};return(0,T.jsxs)(`div`,{className:`card kpiband rise mb-16`,children:[[{key:`agents`,label:`Agents`,hash:`#/agents`},{key:`skills`,label:`Skills`,hash:`#/skills`},{key:`laws`,label:`Dictates`,hash:`#/laws`}].map(e=>{let t=n[e.key];return(0,T.jsxs)(`a`,{className:`kseg`,href:e.hash,title:`Open ${e.label}`,children:[(0,T.jsx)(`span`,{className:`kseg-n`+(t===0?` zero`:``),children:t==null?`—`:(0,T.jsx)(d,{value:t})}),(0,T.jsx)(`span`,{className:`kseg-l`,children:e.label})]},e.key)}),(0,T.jsx)(`div`,{className:`kseg-spacer`}),(0,T.jsxs)(`button`,{className:`kseg`+(t>0?` hot`:``),onClick:()=>y(`#/diff`),title:`Open changes`,children:[(0,T.jsx)(`span`,{className:`kseg-n`+(t===0?` zero`:``),children:(0,T.jsx)(d,{value:t})}),(0,T.jsx)(`span`,{className:`kseg-l`,children:`Local edits`}),t>0&&(0,T.jsx)(`span`,{className:`delta up`,children:`▲`})]})]})}function O({overview:t}){return(0,T.jsx)(`div`,{className:`genome`,children:n.map((n,r)=>{let i=e[n],a=t.counts?.[n];return(0,T.jsxs)(`div`,{className:`card gcell rise`,style:{"--i":r},onClick:()=>y(`#/section/`+n),children:[(0,T.jsxs)(`div`,{className:`gtop`,children:[(0,T.jsx)(`span`,{className:`gname`,children:i.label}),(0,T.jsx)(p,{name:i.icon,className:`gicon`})]}),(0,T.jsx)(`div`,{className:`gcount`+(a===0?` zero`:``),children:a==null?`—`:(0,T.jsx)(d,{value:a})}),(0,T.jsx)(`div`,{className:`gdesc`,children:i.desc})]},n)})})}function k({jobs:e}){if(!e||e.length===0)return(0,T.jsx)(`div`,{className:`feed`,children:(0,T.jsxs)(`div`,{className:`empty`,children:[(0,T.jsx)(`div`,{className:`big`,children:`No activity yet`}),`Actions you run appear here.`]})});let t={done:`ok`,running:`acc`,failed:`bad`},n=[...e].sort((e,t)=>t.started-e.started).slice(0,8);return(0,T.jsx)(`div`,{className:`feed`,children:n.map(e=>(0,T.jsxs)(`div`,{className:`feed-row`,children:[(0,T.jsx)(`span`,{className:`feed-dot ${t[e.status]||`ok`}`}),(0,T.jsx)(`span`,{className:`feed-txt`,children:(0,T.jsx)(`b`,{children:e.action})}),(0,T.jsxs)(`span`,{className:`feed-when`,children:[m(e.started),` ago`]})]},e.id))})}function A({overview:e,sigil:t,setup:r,jobs:i,onAction:a}){let o=w(e),s=f(e,r);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`card pad-lg rise mb-16`,children:(0,T.jsxs)(`div`,{className:`hero`,children:[(0,T.jsx)(E,{value:s}),(0,T.jsxs)(`div`,{className:`hero-facts`,children:[(0,T.jsx)(`div`,{className:`ttl`,children:o}),t&&(0,T.jsxs)(`div`,{className:`voice-readout`,children:[(0,T.jsx)(`span`,{className:`vr-cur`,children:`▕`}),(0,T.jsx)(`span`,{className:`vr-txt`,children:t})]},e.theme),(0,T.jsxs)(`p`,{className:`sub`,children:[`One source rendered into `,(0,T.jsx)(`code`,{children:e.target}),`. Every repo on this machine inherits it.`]}),(0,T.jsxs)(`div`,{className:`hero-chips`,children:[(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`voice`}),(0,T.jsx)(`span`,{className:`cv`,style:{textTransform:`capitalize`},children:e.theme})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`mode`}),(0,T.jsx)(`span`,{className:`cv`,children:e.emit})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`footprint`}),(0,T.jsx)(`span`,{className:`cv`,children:e.footprint})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`built`}),(0,T.jsx)(`span`,{className:`cv`,children:e.build_time||`unknown`})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`fp`}),(0,T.jsx)(`span`,{className:`cv`,children:r?.installed_fp||`—`})]})]}),(0,T.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,T.jsxs)(`button`,{className:`btn`,onClick:()=>a(`update`),children:[(0,T.jsx)(p,{name:`refresh`}),`Update`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`build-all`),children:[(0,T.jsx)(p,{name:`build`}),`Rebuild`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`doctor`),children:[(0,T.jsx)(p,{name:`doctor`}),`Run doctor`]})]})]})]})}),(0,T.jsx)(D,{overview:e}),(0,T.jsxs)(`div`,{className:`grid split-status`,children:[(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsxs)(`div`,{className:`card-head`,children:[(0,T.jsx)(`h3`,{children:`Capability genome`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsxs)(`span`,{className:`tick`,children:[n.length,` sections`]})})]}),(0,T.jsx)(O,{overview:e})]}),(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsxs)(`div`,{className:`card-head`,children:[(0,T.jsx)(`h3`,{children:`Recent activity`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsxs)(`span`,{className:`badge acc`,children:[(0,T.jsx)(`span`,{className:`dot`}),`live`]})})]}),(0,T.jsx)(k,{jobs:i})]})]})]})}function j({k:t,overview:n,max:r}){let i=e[t],a=n.counts?.[t]??0;return(0,T.jsxs)(`div`,{className:`strand`,children:[(0,T.jsxs)(`span`,{className:`strand-name`,children:[(0,T.jsx)(`span`,{className:`strand-dot`}),(0,T.jsx)(`a`,{href:`#/section/`+t,className:`strand-link stretch-link`,children:i.label})]}),(0,T.jsx)(`div`,{className:`hbar`,children:(0,T.jsx)(`i`,{style:{width:`${a/r*100}%`}})}),(0,T.jsx)(`span`,{className:`strand-val`,children:a})]})}function M({overview:e,sigil:t,setup:r,jobs:i}){let a=u(e.counts),o=r?.version_verdict||``,s=o.includes(`up to date`),c=l(e.diff),d=[[`Source`,`src/, the canonical genetic material`,r?.source_fp||`—`,!0],[`Render`,`geneseed build → ${e.emit}`,e.theme+` voice`,!0],[`Deployed`,e.target,`inherited by every repo`,!1]];return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`mb-16`,children:(0,T.jsxs)(`div`,{className:`card pad-lg rise`,style:{position:`relative`,overflow:`hidden`},children:[(0,T.jsx)(`h2`,{className:`h`,style:{fontSize:22,margin:`0 0 18px`},children:`Gene-seed lineage`}),(0,T.jsxs)(`div`,{className:`lineage-track`,children:[(0,T.jsx)(`div`,{className:`spine`}),d.map(([e,t,n,r],i)=>(0,T.jsxs)(`div`,{className:`lineage-step`,children:[(0,T.jsx)(`span`,{className:`node ${r?`on`:``}`}),(0,T.jsx)(`div`,{className:`lt`,children:e}),(0,T.jsx)(`div`,{className:`ld`,children:t}),(0,T.jsx)(`div`,{className:`ltag`,children:n})]},i))]}),(0,T.jsx)(`hr`,{className:`hr`}),t&&(0,T.jsxs)(`div`,{className:`voice-readout`,style:{marginBottom:14},children:[(0,T.jsx)(`span`,{className:`vr-cur`,children:`▕`}),(0,T.jsx)(`span`,{className:`vr-txt`,children:t})]},e.theme),(0,T.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,T.jsxs)(`span`,{className:`badge ${s?`ok`:`warn`}`,children:[(0,T.jsx)(`span`,{className:`dot`}),`in sync · `,o]}),(0,T.jsxs)(`span`,{className:`badge`,children:[(0,T.jsx)(`span`,{className:`dot`}),c,` local edits`]})]})]})}),(0,T.jsxs)(`div`,{className:`grid split-even`,children:[(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsxs)(`div`,{className:`card-head`,children:[(0,T.jsx)(`h3`,{children:`Genome strand`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsx)(`span`,{className:`tick`,children:`by volume`})})]}),n.map(t=>(0,T.jsx)(j,{k:t,overview:e,max:a},t))]}),(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsx)(`div`,{className:`card-head`,children:(0,T.jsx)(`h3`,{children:`Recent activity`})}),(0,T.jsx)(k,{jobs:i})]})]})]})}function N({overview:t,setup:r,jobs:i}){let a=n.reduce((e,n)=>e+(t.counts?.[n]??0),0),o=u(t.counts),s=t.doctor?.ok,c=t.doctor?.problems?.length??0,d=l(t.diff);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`card pad-md rise mb-16`,children:(0,T.jsx)(`div`,{className:`row wrap between gap-16`,children:(0,T.jsxs)(`div`,{className:`row`,style:{gap:20,flexWrap:`wrap`},children:[(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`status`}),(0,T.jsx)(`div`,{className:`row`,style:{gap:8,marginTop:4},children:(0,T.jsxs)(`span`,{className:`badge ${t.deployed?`ok`:`warn`}`,children:[(0,T.jsx)(`span`,{className:`dot`}),t.deployed?`deployed`:`not deployed`]})})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`voice`}),(0,T.jsx)(`div`,{className:`metric`,style:{fontSize:18,marginTop:6,textTransform:`capitalize`},children:t.theme})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`mode`}),(0,T.jsx)(`div`,{className:`mono`,style:{fontSize:14,marginTop:6},children:t.emit})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`fingerprint`}),(0,T.jsx)(`div`,{className:`mono`,style:{fontSize:14,marginTop:6,color:`var(--accent)`},children:r?.installed_fp||`—`})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`doctor`}),(0,T.jsx)(`div`,{className:`row`,style:{gap:8,marginTop:4},children:s?(0,T.jsxs)(`span`,{className:`badge ok`,children:[(0,T.jsx)(`span`,{className:`dot`}),`clean`]}):(0,T.jsxs)(`span`,{className:`badge warn`,children:[(0,T.jsx)(`span`,{className:`dot`}),c,` issue`,c===1?``:`s`]})})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`edits`}),(0,T.jsx)(`div`,{className:`metric`,style:{fontSize:18,marginTop:6},children:d})]})]})})}),(0,T.jsxs)(`div`,{className:`grid split-operator`,children:[(0,T.jsxs)(`div`,{className:`card rise`,style:{"--i":1},children:[(0,T.jsxs)(`div`,{className:`card-head pad-lg`,style:{padding:`18px 20px 0`,marginBottom:14},children:[(0,T.jsx)(`h3`,{children:`Sections`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsxs)(`span`,{className:`tick`,children:[a,` entries total`]})})]}),(0,T.jsxs)(`table`,{className:`tbl`,children:[(0,T.jsx)(`thead`,{children:(0,T.jsxs)(`tr`,{children:[(0,T.jsx)(`th`,{children:`Section`}),(0,T.jsx)(`th`,{children:`Detail`}),(0,T.jsx)(`th`,{style:{width:130},children:`Share`}),(0,T.jsx)(`th`,{className:`num`,children:`Count`})]})}),(0,T.jsx)(`tbody`,{children:n.map(n=>{let r=e[n],i=t.counts?.[n]??0;return(0,T.jsxs)(`tr`,{className:`clickable`,children:[(0,T.jsx)(`td`,{className:`name`,children:(0,T.jsx)(`a`,{href:`#/section/`+n,className:`stretch-link`,children:r.label})}),(0,T.jsx)(`td`,{className:`muted`,children:r.desc}),(0,T.jsx)(`td`,{children:(0,T.jsx)(`div`,{className:`hbar`,children:(0,T.jsx)(`i`,{style:{width:`${i/o*100}%`}})})}),(0,T.jsx)(`td`,{className:`num`,children:i})]},n)})})]})]}),(0,T.jsxs)(`div`,{className:`card pad-lg rise`,style:{"--i":2},children:[(0,T.jsx)(`div`,{className:`card-head`,children:(0,T.jsx)(`h3`,{children:`Run log`})}),(0,T.jsx)(k,{jobs:i})]})]})]})}function P(){let[e,t]=(0,S.useState)(!1),[n,r]=(0,S.useState)(null);return(0,T.jsxs)(`div`,{className:`stale-banner`,role:`alert`,children:[(0,T.jsx)(`span`,{children:n||`This console is running code from before your last upgrade.`}),(0,T.jsx)(`button`,{className:`btn sm`,onClick:async()=>{t(!0),r(null);try{await g()}catch(e){r(e.message),t(!1)}},disabled:e,children:e?`Restarting…`:`Restart`})]})}var F=t({default:()=>z}),I=(0,S.lazy)(()=>b(()=>import(`./GreenhouseView-zk2Uzc3A.js`),__vite__mapDeps([0,1,2,3,4,5,6,7]))),L=(0,S.lazy)(()=>b(()=>import(`./OperatorHudView-CyiGhiHk.js`),__vite__mapDeps([8,1,2,4,5,6,7]))),R=(0,S.lazy)(()=>b(()=>import(`./JournalView-Bfj27XHC.js`),__vite__mapDeps([9,1,2,5,3,4,6])));function z({overview:e,overviewError:t,onRetry:n,themes:r,setup:i,runs:a,onAction:l,layout:u=`cultivar`,dataRev:d}){let f=u,[p,m]=(0,S.useState)(`status`),g=e&&r.find(t=>t.name===e.theme)?.sigil||``,{data:_}=s(()=>f===`greenhouse`||f===`operator`?o.doctor().catch(()=>null):Promise.resolve(null),[f,d]),{data:y}=s(()=>f===`journal`?o.recent().catch(()=>null):Promise.resolve(null),[f,d]);if(!e)return t?(0,T.jsxs)(`div`,{children:[(0,T.jsx)(x,{error:`Could not load the harness overview: ${t}`}),(0,T.jsx)(`button`,{className:`btn`,onClick:n,children:`Retry`})]}):(0,T.jsx)(c,{});let b=e.daemon_stale?(0,T.jsx)(P,{}):null;return e.deployed?p===`status`&&f===`journal`?(0,T.jsxs)(S.Suspense,{fallback:(0,T.jsx)(c,{}),children:[b,(0,T.jsx)(R,{overview:e,recent:y,onAction:l,onDirection:m,dataRev:d})]}):(0,T.jsxs)(T.Fragment,{children:[b,(0,T.jsx)(`div`,{className:`head-row`,children:(0,T.jsx)(h,{"aria-label":`Dashboard view`,children:[[`status`,`Status`],[`lineage`,`Lineage`],[`operator`,`Operator`]].map(([e,t])=>(0,T.jsx)(`button`,{className:p===e?`on`:``,onClick:()=>m(e),"aria-pressed":p===e,children:t},e))})}),(0,T.jsxs)(`div`,{className:`view-in`,children:[p===`status`&&f===`cultivar`&&(0,T.jsx)(A,{overview:e,sigil:g,setup:i,jobs:a,onAction:l}),p===`status`&&f===`greenhouse`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(c,{}),children:(0,T.jsx)(I,{overview:e,sigil:g,jobs:a,doctor:_,onAction:l})}),p===`status`&&f===`operator`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(c,{}),children:(0,T.jsx)(L,{overview:e,jobs:a,doctor:_,onAction:l})}),p===`lineage`&&(0,T.jsx)(M,{overview:e,sigil:g,setup:i,jobs:a}),p===`operator`&&(0,T.jsx)(N,{overview:e,setup:i,jobs:a})]},p)]}):(0,T.jsxs)(T.Fragment,{children:[b,(0,T.jsx)(v,{onAction:l})]})}export{z as default,w as n,F as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./sections-BET3c1WT.js";import{i as e,t}from"./react-BOF6yL40.js";e();var n=t();function r({value:e,onChange:t,label:r,placeholder:i,className:a}){return(0,n.jsx)(`input`,{className:a||`lib-filter`,type:`text`,value:e,onChange:e=>t(e.target.value),placeholder:i,"aria-label":r||i})}export{r as t};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{n as e,r as t,s as n}from"./sections-BET3c1WT.js";import{i as r,t as i}from"./react-BOF6yL40.js";import{t as a}from"./drawable-CyLe1gtW.js";import{F as o,J as s,N as c,X as l,Y as u,et as d,rt as f}from"./index-DQXG_mqo.js";import{t as p}from"./jobBuckets-Dbq8ZlWW.js";import{n as m}from"./Dashboard-C5ATa3ow.js";var h=n(r(),1),g=i(),_=12,v=120,y=[`#2BB673`,`#16A6A6`,`#E8A23B`,`#E07A5F`,`#8E7DBE`,`#5BD08A`,`#79856E`],b=650;function x({segments:e,size:t=186,stroke:n=26,caption:r=`capabilities`}){let i=e.reduce((e,t)=>e+t.value,0)||1,o=(0,h.useRef)(null),c=e.map(e=>e.value).join(`,`);(0,h.useLayoutEffect)(()=>{let t=o.current?.querySelectorAll(`path`);if(!t?.length||!u())return;let n=e.filter(e=>e.value>0).map(e=>e.value/i),r=n.map((e,t)=>n.slice(0,t).reduce((e,t)=>e+t,0)),s=a(t);d(s,{draw:`0 0`});let c=f(s,{draw:[`0 0`,`0 1`],duration:(e,t)=>Math.max(b*n[t],60),delay:(e,t)=>b*r[t],ease:`linear`});return l(c,b)},[c]);let p=t/2-n/2,m=t/2,_=t/2,v=[],y=0;for(let t of e)v.push(y),y+=t.value;return(0,g.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 ${t} ${t}`,children:[(0,g.jsx)(`circle`,{cx:m,cy:_,r:p,fill:`none`,stroke:`var(--surface-3)`,strokeWidth:n}),(0,g.jsx)(`g`,{ref:o,children:e.map((e,t)=>{if(e.value/i<=0)return null;let r=v[t]/i*2*Math.PI-Math.PI/2,a=(v[t]+e.value)/i*2*Math.PI-Math.PI/2,o=m+p*Math.cos(r),s=_+p*Math.sin(r),c=m+p*Math.cos(a),l=_+p*Math.sin(a),u=+(a-r>Math.PI);return(0,g.jsx)(`path`,{d:`M ${o} ${s} A ${p} ${p} 0 ${u} 1 ${c} ${l}`,fill:`none`,stroke:e.color,strokeWidth:n,strokeLinecap:`butt`,children:(0,g.jsxs)(`title`,{children:[e.label,`: `,e.value]})},t)})}),(0,g.jsx)(`text`,{x:m,y:_-4,textAnchor:`middle`,className:`donut-c-num`,children:(0,g.jsx)(s,{value:i,duration:b})}),(0,g.jsx)(`text`,{x:m,y:_+16,textAnchor:`middle`,className:`donut-c-cap`,children:r})]})}function S(e){if(e.length<2)return e.length?`M${e[0][0]},${e[0][1]}`:``;let t=`M${e[0][0]},${e[0][1]}`;for(let n=0;n<e.length-1;n++){let r=e[n-1]||e[n],i=e[n],a=e[n+1],o=e[n+2]||a,s=i[0]+(a[0]-r[0])/6,c=i[1]+(a[1]-r[1])/6,l=a[0]-(o[0]-i[0])/6,u=a[1]-(o[1]-i[1])/6;t+=` C${s},${c} ${l},${u} ${a[0]},${a[1]}`}return t}function C({data:e,height:t=156,accent:n}){if(!e.length)return null;let r=t,i=Math.max(...e.map(e=>e.v),1)+1,a=e.length>1?588/(e.length-1):588,o=e.map((e,t)=>[6+t*a,r-6-e.v/i*(r-14-6)]),s=S(o),c=o[o.length-1],l=o[0],u=`${s} L${c[0]},${r} L${l[0]},${r} Z`;return(0,g.jsxs)(`svg`,{viewBox:`0 0 600 ${r}`,preserveAspectRatio:`none`,style:{width:`100%`,height:t,display:`block`,overflow:`visible`},children:[(0,g.jsx)(`defs`,{children:(0,g.jsxs)(`linearGradient`,{id:`b-grad`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,g.jsx)(`stop`,{offset:`0`,stopColor:n,stopOpacity:`.28`}),(0,g.jsx)(`stop`,{offset:`1`,stopColor:n,stopOpacity:`0`})]})}),(0,g.jsx)(`path`,{d:u,fill:`url(#b-grad)`}),(0,g.jsx)(`path`,{d:s,fill:`none`,stroke:n,strokeWidth:`2`,strokeLinejoin:`round`,strokeLinecap:`round`,vectorEffect:`non-scaling-stroke`}),(0,g.jsx)(`circle`,{cx:c[0],cy:c[1],r:`3.5`,fill:n,vectorEffect:`non-scaling-stroke`})]})}function w({label:e,value:t,sub:n,color:r,icon:i}){return(0,g.jsxs)(`div`,{className:`b-tile`,children:[(0,g.jsx)(`span`,{className:`b-tile-ic`,style:{background:`color-mix(in srgb, ${r} 18%, transparent)`,color:r},children:(0,g.jsx)(c,{name:i})}),(0,g.jsxs)(`div`,{className:`b-tile-body`,children:[(0,g.jsx)(`div`,{className:`b-tile-val`+(t===0?` zero`:``),children:t}),(0,g.jsx)(`div`,{className:`b-tile-label`,children:e})]}),(0,g.jsx)(`div`,{className:`b-tile-sub`,children:n})]})}function T({overview:n,sigil:r,jobs:i,doctor:a,onAction:l}){let u=n.counts||{},d=a?.groups||[],f=d.length>0,h=d.filter(e=>e.problems.length===0).length,b=d.length||1,S=m(n),T=o(n.diff),E=t.filter(e=>(u[e]||0)>0).map((t,n)=>({label:e[t].label,value:u[t]||0,color:y[n%y.length]})),D=E.reduce((e,t)=>e+t.value,0),O=p(i||[],10),k=O.reduce((e,t)=>e+t.v,0);return(0,g.jsxs)(g.Fragment,{children:[(0,g.jsxs)(`div`,{className:`b-greet`,children:[(0,g.jsxs)(`div`,{children:[(0,g.jsx)(`div`,{className:`eyebrow`,children:`your harness`}),(0,g.jsx)(`h1`,{className:`h b-h`,children:S}),(0,g.jsx)(`p`,{className:`sub`,children:r||`A friendly read of every layer growing in your harness.`})]}),(0,g.jsxs)(`div`,{className:`row gap-8`,children:[(0,g.jsxs)(`button`,{className:`btn`,onClick:()=>l(`update`),children:[(0,g.jsx)(c,{name:`refresh`}),`Update`]}),(0,g.jsxs)(`button`,{className:`btn ghost`,onClick:()=>l(`build-all`),children:[(0,g.jsx)(c,{name:`build`}),`Rebuild`]})]})]}),(0,g.jsxs)(`div`,{className:`grid b-hero-grid mb-16`,children:[(0,g.jsxs)(`div`,{className:`card b-hero`,children:[(0,g.jsx)(`div`,{className:`b-hero-ring`,children:(0,g.jsx)(x,{segments:[{label:`pass`,value:h,color:y[0]},{label:`attention`,value:Math.max(b-h,0),color:y[2]}],size:168,stroke:20,caption:`checks`})}),(0,g.jsxs)(`div`,{className:`b-hero-side`,children:[(0,g.jsx)(`h3`,{className:`b-hero-title`,children:f?`${h} of ${b} checks pass`:`Running checks…`}),(0,g.jsxs)(`p`,{className:`sub`,children:[`One source, rendered into `,(0,g.jsx)(`code`,{children:n.target}),` and inherited by every repo on this machine.`]}),f&&(0,g.jsx)(`ul`,{className:`b-hero-checks`,children:d.map(e=>{let t=e.problems.length===0;return(0,g.jsxs)(`li`,{className:`b-hcheck ${t?`ok`:`bad`}`,title:t?`clean`:e.problems.join(`; `),children:[(0,g.jsx)(`span`,{className:`b-hcheck-mark`,children:t?`✓`:`!`}),(0,g.jsx)(`span`,{className:`b-hcheck-label`,children:e.label})]},e.label)})}),(0,g.jsxs)(`div`,{className:`b-chips`,children:[(0,g.jsxs)(`span`,{className:`b-chip`,children:[(0,g.jsx)(`b`,{style:{textTransform:`capitalize`},children:n.theme}),` voice`]}),(0,g.jsx)(`span`,{className:`b-chip`,children:(0,g.jsx)(`b`,{children:n.emit})}),(0,g.jsxs)(`span`,{className:`b-chip`,children:[`built `,(0,g.jsx)(`b`,{children:n.build_time||`unknown`})]})]})]})]}),(0,g.jsxs)(`div`,{className:`b-tiles`,children:[(0,g.jsx)(w,{label:`Agents`,value:u.agents??`—`,sub:`specialists`,color:y[0],icon:`layers`}),(0,g.jsx)(w,{label:`Skills`,value:u.skills??`—`,sub:`workflows`,color:y[1],icon:`skill`}),(0,g.jsx)(w,{label:`Dictates`,value:u.laws??`—`,sub:u.doctrines?`${u.doctrines.active}/${u.doctrines.total} packs · ${u.doctrines.rules} rules`:`all upheld`,color:y[2],icon:`law`}),(0,g.jsx)(w,{label:`Edits`,value:T,sub:`to graft`,color:y[3],icon:`changes`})]})]}),(0,g.jsxs)(`div`,{className:`grid split-even mb-16`,children:[(0,g.jsxs)(`div`,{className:`card pad-lg b-mix-card`,children:[(0,g.jsxs)(`div`,{className:`card-head`,children:[(0,g.jsx)(`h3`,{children:`Capability mix`}),(0,g.jsx)(`div`,{className:`right`,children:(0,g.jsxs)(`span`,{className:`tick`,children:[D,` total`]})})]}),(0,g.jsxs)(`div`,{className:`b-mix`,children:[(0,g.jsx)(x,{segments:E,size:186,stroke:26}),(0,g.jsx)(`div`,{className:`b-legend`,children:E.map(e=>(0,g.jsxs)(`div`,{className:`b-leg-row`,children:[(0,g.jsx)(`span`,{className:`b-leg-dot`,style:{background:e.color}}),(0,g.jsx)(`span`,{className:`b-leg-name`,children:e.label}),(0,g.jsx)(`span`,{className:`b-leg-bar`,children:(0,g.jsx)(`i`,{style:{width:`${e.value/D*100}%`,background:e.color}})}),(0,g.jsx)(`span`,{className:`b-leg-val`,children:e.value})]},e.label))})]})]}),(0,g.jsxs)(`div`,{className:`card pad-lg`,children:[(0,g.jsxs)(`div`,{className:`card-head`,children:[(0,g.jsx)(`h3`,{children:`Recent runs`}),(0,g.jsx)(`div`,{className:`right`,children:(0,g.jsxs)(`span`,{className:`badge ok`,children:[(0,g.jsx)(`span`,{className:`dot`}),`job log`]})})]}),(0,g.jsxs)(`div`,{className:`b-stat-lead`,children:[(0,g.jsx)(`span`,{className:`b-stat-big`,children:(0,g.jsx)(s,{value:k})}),(0,g.jsxs)(`span`,{className:`b-stat-cap`,children:[`runs in the last 10 days · `,h,`/`,b,` checks pass now`]})]}),(0,g.jsx)(C,{data:O,accent:y[0],height:156})]})]}),(0,g.jsxs)(`div`,{className:`card pad-lg`,children:[(0,g.jsxs)(`div`,{className:`card-head`,children:[(0,g.jsx)(`h3`,{children:`Recent activity`}),(0,g.jsx)(`div`,{className:`right`,children:(0,g.jsxs)(`span`,{className:`tick`,children:[`last `,Math.min(i?.length||0,12),` runs`]})})]}),(0,g.jsxs)(`div`,{className:`b-timeline`,children:[(i||[]).slice(0,_).map(e=>{let t=e.status===`done`,n=e.status===`failed`?`warn`:t?`ok`:`acc`;return(0,g.jsxs)(`div`,{className:`b-tl-row`,children:[(0,g.jsx)(`span`,{className:`b-tl-node ${n}`}),(0,g.jsxs)(`div`,{className:`b-tl-body`,children:[(0,g.jsx)(`b`,{children:e.action}),e.output?`: ${e.output.split(`
|
|
2
|
-
`)[0].slice(0,v)}`:``]}),(0,g.jsx)(`span`,{className:`b-tl-when`,children:e.duration?`${e.duration}s`:e.status})]},e.id)}),(!i||i.length===0)&&(0,g.jsxs)(`div`,{className:`b-tl-row`,children:[(0,g.jsx)(`span`,{className:`b-tl-node`}),(0,g.jsx)(`div`,{className:`b-tl-body sub`,children:`No runs yet. Trigger an action to populate this.`}),(0,g.jsx)(`span`,{className:`b-tl-when`,children:`—`})]})]})]})]})}export{T as default};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{A as i,B as a,C as o,H as s,M as c,N as l,P as u,S as d,T as f,U as p,V as m,W as h,j as g,k as _,w as v,x as y}from"./index-DQXG_mqo.js";import{t as b}from"./Tabs-BOD7Kaz1.js";var x=e(t(),1),S=n();function C({label:e,value:t,options:n,onChange:r}){return n.length?(0,S.jsx)(`select`,{className:`sel`,"aria-label":e,value:t,onChange:e=>r(e.target.value),children:n.map(e=>(0,S.jsx)(`option`,{value:e,children:e},e))}):null}var w=[`full`,`lean`];function T({on:e,disabled:t,label:n,onToggle:r}){return(0,S.jsx)(`input`,{type:`checkbox`,role:`switch`,className:`sw-toggle${e?` on`:``}`,checked:e,"aria-checked":e,disabled:t,"aria-label":n,onChange:r,onKeyDown:e=>{e.key===`Enter`&&!t&&r()}})}var E=[{key:`theme`,name:`voice`,title:`Voice`},{key:`footprint`,name:`footprint`,title:`Footprint`},{key:`posture`,name:`posture`,title:`Posture`},{key:`mode`,name:`mode`,title:`Mode`},{key:`trust`,name:`trust`,title:`Loop trust`}];function D({value:e,options:t,onChange:n,who:r}){return E.map(i=>(0,S.jsxs)(`label`,{className:`dp-field`,children:[(0,S.jsx)(`span`,{children:i.title}),(0,S.jsx)(C,{label:`${i.name} for ${r}`,value:e[i.key],options:t[i.key],onChange:e=>n(i.key,e)})]},i.key))}function O({host:e,theme:t,options:n,onAction:a,onClose:o,onNote:s}){let[c,l]=(0,x.useState)({path:``,host:e,theme:t,footprint:`full`,posture:`peer`,mode:`direct`,trust:`balanced`}),[u,d]=(0,x.useState)(!1),f=(e,t)=>l(n=>({...n,[e]:t})),p=async()=>{d(!0),s(``);try{let e=await r.pickFolder();e.path?f(`path`,e.path):e.error&&s(e.error)}catch(e){s(e.message)}finally{d(!1)}},m=async()=>{let e=c.path.trim();if(!e){s(`Choose or type a folder to deploy into.`);return}s(``),await a?.(`deploy`,{host:c.host,path:e,theme:c.theme,footprint:c.footprint,posture:c.posture,mode:c.mode,trust:c.trust})&&o()};return(0,S.jsxs)(`div`,{className:`deploy-pop`,children:[(0,S.jsxs)(`div`,{className:`dp-row`,children:[(0,S.jsx)(`input`,{className:`inp dp-path`,type:`text`,placeholder:`/path/to/project, or click Browse…`,value:c.path,onChange:e=>f(`path`,e.target.value),onKeyDown:e=>e.key===`Enter`&&m(),"aria-label":`Folder to deploy into`}),(0,S.jsx)(`button`,{className:`btn ghost sm`,disabled:u,onClick:p,children:u?`Choosing…`:`Browse…`})]}),(0,S.jsxs)(`div`,{className:`dp-row`,children:[(0,S.jsxs)(`label`,{className:`dp-field`,children:[(0,S.jsx)(`span`,{children:`Deploy as`}),(0,S.jsx)(`select`,{className:`sel`,"aria-label":`host for the new harness`,value:c.host,onChange:e=>f(`host`,e.target.value),children:_.map(e=>(0,S.jsx)(`option`,{value:e.id,children:e.label},e.id))})]}),(0,S.jsx)(D,{value:c,options:n,onChange:f,who:`the new harness`}),(0,S.jsx)(`button`,{className:`btn sm`,onClick:m,children:`Deploy`}),(0,S.jsx)(`button`,{className:`btn ghost sm`,onClick:o,children:`Cancel`})]}),(0,S.jsxs)(`p`,{className:`sub dp-note`,children:[`Adds a per-repo harness (`,(0,S.jsx)(`code`,{children:i(c.host).deployAdds}),`) into the folder, non-destructively. It’s then tracked here even after you leave its directory.`]})]})}function k(){let{data:e,error:t,reload:n}=a(()=>r.excludes(),[]),[i,o]=(0,x.useState)(!1),[s,c]=(0,x.useState)([]),u=async(e,t)=>{o(!0);try{let n=await r.excludeMutate(e,t);c(n.messages||[])}catch(e){c(e.body?.messages||[e.message])}finally{o(!1),n()}};return t||!e?.installs?.length?null:(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Excluded folders`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`Sovereign repos: inside these folders every global harness goes dormant — hooks stay silent and the global preamble is not loaded.`}),(e.excludes||[]).map(e=>(0,S.jsxs)(`div`,{className:`row wrap between gap-12`,children:[(0,S.jsx)(`code`,{children:e.path}),(0,S.jsxs)(`span`,{className:`mono muted`,children:[`[`,e.hosts.join(`, `),`]`]}),(0,S.jsx)(`button`,{className:`btn ghost sm`,disabled:i,onClick:()=>u(`remove`,e.path),children:`Remove`})]},e.path)),(0,S.jsxs)(`button`,{className:`btn ghost sm`,disabled:i,onClick:async()=>{o(!0);try{let e=await r.pickFolder();e.path?await u(`add`,e.path):e.error&&c([e.error])}catch(e){c([e.message])}finally{o(!1)}},children:[(0,S.jsx)(l,{name:`folder`}),` Exclude a folder…`]}),s.map((e,t)=>(0,S.jsx)(`p`,{className:`sub`,children:e},t))]})}function A({inst:e,memory:t,busy:n,onMemory:r,onRemove:i,onCancel:a}){return(0,S.jsxs)(`div`,{className:`h-remove`,children:[(0,S.jsxs)(`p`,{className:`hr-msg`,children:[(0,S.jsx)(`strong`,{children:e.scope===`project`?`Remove this harness from the folder?`:`Remove the global ${e.host} install?`}),` `,(0,S.jsxs)(`span`,{className:`sub`,children:[`Deletes `,(0,S.jsx)(`code`,{children:c(e.host,e.scope)}),e.scope===`project`?` and de-lists it.`:`; the row stays, marked “not installed.”`,` `,`This can’t be undone.`]})]}),(0,S.jsxs)(`label`,{className:`field`,children:[(0,S.jsx)(`span`,{children:`Memory and notebook`}),(0,S.jsxs)(`select`,{className:`sel`,"aria-label":`memory disposition`,value:t,onChange:e=>r(e.target.value),children:[(0,S.jsx)(`option`,{value:`keep`,children:`keep in place`}),(0,S.jsx)(`option`,{value:`archive`,children:`archive aside`}),(0,S.jsx)(`option`,{value:`delete`,children:`delete too`})]})]}),(0,S.jsxs)(`div`,{className:`row gap-8`,children:[(0,S.jsx)(`button`,{type:`button`,className:`btn danger`,disabled:n,onClick:i,children:n?`Removing…`:`Remove`}),(0,S.jsx)(`button`,{type:`button`,className:`btn ghost`,onClick:a,children:`Cancel`})]})]})}function j({targets:e,onReveal:t}){let n=e.flatMap(e=>e.servers);return(0,S.jsxs)(`div`,{className:`ip-block`,children:[(0,S.jsxs)(`span`,{className:`ip-label`,children:[`MCP servers `,(0,S.jsx)(`span`,{className:`mono dim`,children:n.length})]}),e.map(e=>(0,S.jsxs)(`div`,{className:`mcp-target`,children:[(0,S.jsxs)(`div`,{className:`mt-head`,children:[(0,S.jsx)(`code`,{title:e.path,children:e.label}),(0,S.jsx)(`button`,{type:`button`,className:`btn ghost sm`,onClick:()=>t(e),title:`Open the folder holding ${e.path} to edit it`,children:`Open folder`})]}),e.servers.length?e.servers.map(e=>(0,S.jsxs)(`div`,{className:`mcp-row`,children:[(0,S.jsx)(`span`,{className:`mono`,children:e.name}),(0,S.jsx)(`span`,{className:`tag ${e.state===`enabled`?`ok`:`warn`}`,children:e.state===`enabled`?`Enabled`:`Disabled`})]},e.name)):(0,S.jsx)(`p`,{className:`sub`,children:`None configured in this file.`})]},e.path))]})}var M={active:[`Active`,`ok`],disabled:[`Disabled`,`warn`],absent:[`Not installed`,``]};function N({inst:e,targets:t,choice:n,unchanged:r,options:a,onPick:o,canAct:s,busy:c,removing:l,onRemoving:u,onApply:d,onToggleInstall:f,onRemove:p,onRevealMcp:m}){let h=`${e.host} · ${e.scope}`,[_,v]=M[e.state]||M.absent,y=e.state===`active`,b=e.state===`absent`;return(0,S.jsxs)(`aside`,{className:`install-panel`,"aria-label":`${h} install`,children:[(0,S.jsx)(`span`,{className:`ip-eyebrow`,children:`Selected install`}),(0,S.jsxs)(`div`,{className:`ip-head`,children:[(0,S.jsx)(`h2`,{children:g(e)}),(0,S.jsx)(`span`,{className:`tag ${v}`,children:_})]}),(0,S.jsx)(`span`,{className:`ip-kind`,children:e.scope===`global`?`Global install`:`Per-project install · ${i(e.host).label}`}),(0,S.jsx)(`code`,{className:`ip-path`,children:e.path}),b?(0,S.jsxs)(`p`,{className:`sub`,children:[`Install Geneseed here as `,(0,S.jsx)(`strong`,{children:e.host}),`. Files are added non-destructively; deactivate or uninstall later.`]}):null,(y||b)&&s?(0,S.jsx)(`div`,{className:`ip-picks`,children:(0,S.jsx)(D,{value:n,options:a,onChange:o,who:h})}):null,y&&t.length?(0,S.jsx)(j,{targets:t,onReveal:m}):null,y&&e.scope===`global`?(0,S.jsx)(k,{}):null,b?null:(0,S.jsxs)(`label`,{className:`ip-switch`,children:[(0,S.jsx)(T,{on:y,disabled:c,label:`activate ${h}`,onToggle:f}),(0,S.jsx)(`span`,{children:y?`Active: loads in every session`:`Disabled: files moved aside`})]}),(0,S.jsx)(`div`,{className:`ip-spacer`}),s?(0,S.jsxs)(`div`,{className:`ip-actions`,children:[b?(0,S.jsx)(`button`,{type:`button`,className:`btn`,onClick:d,children:`Install`}):y?(0,S.jsx)(`button`,{type:`button`,className:`btn`,disabled:r,onClick:d,children:`Apply and rebuild`}):null,b?null:(0,S.jsx)(`button`,{type:`button`,className:`btn ghost danger-line`,"aria-label":`remove ${h} from ${e.path}`,"aria-expanded":!!l,disabled:c,onClick:()=>u(l?null:{memory:`keep`}),children:`Uninstall…`})]}):null,l?(0,S.jsx)(A,{inst:e,memory:l.memory,busy:c,onMemory:e=>u({memory:e}),onRemove:p,onCancel:()=>u(null)}):null]})}var P=(e,t)=>`${e} ${t}`,F={active:[`Active`,`ok`],disabled:[`Disabled`,`warn`]};function I({rows:e,project:t,currentId:n,onPick:r,label:a}){return(0,S.jsx)(`div`,{className:`tbl-scroll`,children:(0,S.jsxs)(`table`,{className:`tbl hosts-tbl`,"aria-label":a,children:[(0,S.jsx)(`thead`,{children:(0,S.jsxs)(`tr`,{children:[(0,S.jsx)(`th`,{children:t?`Project`:`Host`}),(0,S.jsx)(`th`,{children:t?`Host`:`Path`}),(0,S.jsx)(`th`,{children:`Voice`}),(0,S.jsx)(`th`,{children:`Footprint`}),(0,S.jsx)(`th`,{children:`State`}),(0,S.jsx)(`th`,{children:(0,S.jsx)(`span`,{className:`sr-only`,children:`Selected`})})]})}),(0,S.jsx)(`tbody`,{children:e.map(e=>{let[a,o]=F[e.state]||[`Not installed`,``],s=n===e.id,c=e.state===`absent`;return(0,S.jsxs)(`tr`,{className:`pickable${s?` on`:``}${c?` quiet`:``}`,onClick:()=>r(e.id),children:[(0,S.jsx)(`td`,{children:(0,S.jsx)(`button`,{type:`button`,className:`row-pick`,"aria-pressed":s,title:e.path,onClick:()=>r(e.id),children:g(e)})}),t?(0,S.jsx)(`td`,{children:i(e.host).label}):(0,S.jsx)(`td`,{className:`mono path-cell`,title:e.path,children:e.path}),(0,S.jsx)(`td`,{children:c?``:e.theme||``}),(0,S.jsx)(`td`,{children:c?``:e.footprint||``}),(0,S.jsx)(`td`,{children:(0,S.jsx)(`span`,{className:`tag ${o}`,children:a})}),(0,S.jsx)(`td`,{className:`pick-mark`,children:s?`Editing ›`:``})]},e.id)})})]})})}function L({themes:e,current:t}){if(!e.length||!t)return null;let n=[...e].sort((e,n)=>e.name===t?-1:+(n.name===t));return(0,S.jsxs)(`details`,{className:`panel voice-ref`,children:[(0,S.jsxs)(`summary`,{children:[(0,S.jsx)(`span`,{className:`vr-title`,children:`Voices`}),(0,S.jsxs)(`span`,{className:`mono dim`,children:[e.length,` to choose from, set per install`]})]}),(0,S.jsx)(`div`,{className:`vr-list`,children:n.map(e=>(0,S.jsxs)(`div`,{className:`voice-row${e.name===t?` current`:``}`,children:[(0,S.jsx)(`span`,{className:`vr-name`,children:e.name}),(0,S.jsx)(`span`,{className:`vr-desc`,children:e.tagline?`“${e.tagline}”`:e.blurb})]},e.name))})]})}function R({setup:e,overview:t}){if(!e)return null;let n=e.installed_fp&&e.installed_fp===e.source_fp;return(0,S.jsxs)(`section`,{className:`panel`,"aria-labelledby":`checkout-h`,children:[(0,S.jsxs)(`div`,{className:`panel-head`,children:[(0,S.jsx)(`h2`,{id:`checkout-h`,children:`This checkout`}),(0,S.jsx)(`span`,{className:`mono ${n?`t-good`:`t-warn`}`,children:e.version_verdict})]}),(0,S.jsxs)(`dl`,{className:`kv-grid`,children:[(0,S.jsx)(`dt`,{children:`Source`}),(0,S.jsx)(`dd`,{className:`mono`,children:e.root}),(0,S.jsx)(`dt`,{children:`Version`}),(0,S.jsx)(`dd`,{className:`mono`,children:t?.version||`unknown`}),(0,S.jsx)(`dt`,{children:`Fingerprint`}),(0,S.jsx)(`dd`,{className:`mono`,children:e.source_fp})]})]})}function z({onAction:e,themes:t=[],currentTheme:n,overview:i,setup:s,dataRev:c,onMutated:u}){let f=d(),{data:p,error:m}=a(()=>r.installs(),[c]),{data:h,error:g}=a(()=>r.mcp(),[c]),[_,v]=(0,x.useState)(``),[b,C]=(0,x.useState)(``),[T,E]=(0,x.useState)({}),[D,k]=(0,x.useState)(!1),[A,j]=(0,x.useState)(null),[M,F]=(0,x.useState)(``),z=(0,x.useMemo)(()=>{let e={};for(let t of h?.targets||[]){let n=P(t.host||`opencode`,t.root);(e[n]||(e[n]=[])).push(t)}return e},[h]);if(m||g)return(0,S.jsx)(y,{error:m||g});if(!p||!h)return(0,S.jsx)(o,{});let B={active:0,disabled:1,absent:2},V=[...p.installs].sort((e,t)=>(e.scope===`global`?0:1)-(t.scope===`global`?0:1)||(B[e.state]??3)-(B[t.state]??3)),H=V.find(e=>e.id===M)||V.find(e=>e.selected)||V.find(e=>e.state===`active`)||V[0],U=e=>{let t=T[e.id]||{};return{theme:t.theme||e.theme||n||`neutral`,footprint:t.footprint||e.footprint||`full`,posture:t.posture||e.posture||`peer`,mode:t.mode||e.mode||`direct`,trust:t.trust||e.trust||`balanced`}},W=(e,t,n)=>E(r=>({...r,[e.id]:{...r[e.id],[t]:n}})),G=e=>{let t=U(e);return t.theme===e.theme&&t.footprint===(e.footprint||`full`)&&t.posture===(e.posture||`peer`)&&t.mode===(e.mode||`direct`)&&t.trust===(e.trust||`balanced`)},K={theme:t.map(e=>e.name),footprint:w,posture:p.postures||[],mode:p.modes||[],trust:p.trusts||[]},q=async t=>{let{theme:n,footprint:r,posture:i,mode:a,trust:o}=U(t),s=t.state===`absent`?`Install Geneseed into ${t.path} with the “${n}” voice (${r} footprint, ${i} posture, ${a} mode)? Files are added non-destructively (your own config is left untouched); deactivate or uninstall later.`:`Rebuild this install (voice “${n}”, ${r} footprint, ${i} posture, ${a} mode)? It rebuilds in place, non-destructive.`;await f(s,{title:t.state===`absent`?`Install Geneseed?`:`Rebuild this install?`,confirmLabel:t.state===`absent`?`Install`:`Rebuild`})&&e?.(`install`,{host:t.host,scope:t.scope,path:t.path,theme:n,footprint:r,posture:i,mode:a,trust:o})},J=async e=>{if(e.state!==`active`||await f(`Deactivate this install? Files are moved aside, not deleted; reactivate any time.`,{title:`Deactivate this install?`,confirmLabel:`Deactivate`})){C(e.id),v(``);try{let t=await r.installToggle(e.host,e.path,e.state===`active`?`deactivate`:`activate`);if(!t.ok){let e=Array.isArray(t.failed)?t.failed.join(`, `):``;v(t.error||e&&`unrestored: ${e}`||`action failed`);return}u?.()}catch(e){v(e.message)}finally{C(``)}}},Y=async()=>{let e=A;if(e){C(e.id),v(``);try{let t=await r.installRemove(e.host,e.path,e.memory);if(!t.ok){v(t.error||`remove failed`);return}j(null),t.kept?.length&&v(`Removed. Kept ${t.kept.length} file(s) you edited: ${t.kept.join(`, `)} — they are yours now (the CLI geneseed uninstall --force deletes edited files too).`),u?.()}catch(e){v(e.message)}finally{C(``)}}},X=async e=>{v(``);try{let t=await r.mcpReveal(e.path);v(`Opening ${t.dir}. If no window appeared, open that folder by hand.`)}catch(e){v(e.message)}},Z=V.find(e=>e.selected)?.host||V.find(e=>e.state===`active`)?.host||V[0]?.host||`opencode`,ee=V.filter(e=>e.scope===`global`),Q=V.filter(e=>e.scope!==`global`),$=e=>{F(e),j(null)};return(0,S.jsxs)(`div`,{className:`hosts`,children:[(0,S.jsxs)(`div`,{className:`hosts-main`,children:[(0,S.jsxs)(`div`,{className:`toolbar`,children:[(0,S.jsxs)(`span`,{className:`dim`,children:[V.filter(e=>e.state===`active`).length,` active of `,V.length,` `,`detected.`]}),e?(0,S.jsx)(`div`,{className:`row gap-8`,children:(0,S.jsxs)(`button`,{type:`button`,className:`btn ghost`,onClick:()=>e(`build-all`),children:[(0,S.jsx)(l,{name:`refresh`}),` Rebuild all`]})}):null]}),_?(0,S.jsx)(`p`,{className:`tag bad note`,role:`status`,children:_}):null,(0,S.jsxs)(`section`,{className:`panel flush`,"aria-labelledby":`inst-global`,children:[(0,S.jsx)(`div`,{className:`inst-head`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{id:`inst-global`,children:`Global installs`}),(0,S.jsx)(`p`,{className:`dim`,children:`One per tool. Loaded in every folder, except excluded ones.`})]})}),(0,S.jsx)(I,{rows:ee,currentId:H?.id,onPick:$,label:`Global installs`})]}),(0,S.jsxs)(`section`,{className:`panel flush`,"aria-labelledby":`inst-project`,children:[(0,S.jsxs)(`div`,{className:`inst-head`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{id:`inst-project`,children:`Per-project installs`}),(0,S.jsx)(`p`,{className:`dim`,children:`A repo with its own harness. Inside it, only that harness loads.`})]}),e?(0,S.jsxs)(`button`,{type:`button`,className:`btn ghost`,onClick:()=>k(e=>!e),children:[(0,S.jsx)(l,{name:`folder`}),` Deploy to a repo…`]}):null]}),D?(0,S.jsx)(`div`,{className:`inst-deploy`,children:(0,S.jsx)(O,{host:Z,theme:n||`neutral`,options:K,onAction:e,onClose:()=>k(!1),onNote:v})}):null,Q.length?(0,S.jsx)(I,{rows:Q,project:!0,currentId:H?.id,onPick:$,label:`Per-project installs`}):(0,S.jsx)(`div`,{className:`empty inst-empty`,children:`No repo has its own harness yet. Deploy one to give a project its own rules and voice.`})]}),(0,S.jsx)(R,{setup:s,overview:i}),(0,S.jsx)(L,{themes:t,current:i?.theme})]}),H?(0,S.jsx)(N,{inst:H,targets:z[P(H.host,H.path)]||[],choice:U(H),unchanged:G(H),options:K,onPick:(e,t)=>W(H,e,t),canAct:!!e,busy:b===H.id,removing:A?.id===H.id?A:null,onRemoving:e=>j(e&&{id:H.id,host:H.host,path:H.path,memory:e.memory}),onApply:()=>q(H),onToggleInstall:()=>J(H),onRemove:Y,onRevealMcp:X},H.id):null]})}function B(e){return e.startsWith(`@@`)||e.startsWith(`+++`)||e.startsWith(`---`)?`hunk`:e.startsWith(`+`)?`add`:e.startsWith(`-`)?`del`:`ctx`}function V({onMutated:e,onAction:t,dataRev:n}){let i=d(),{data:s,error:c,reload:u}=a(()=>r.diff(),[n]),[f,p]=(0,x.useState)(!1),[m,h]=(0,x.useState)(``),[g,_]=(0,x.useState)(()=>new Set),[v,b]=(0,x.useState)(()=>new Set),[C,w]=(0,x.useState)(null);s&&s!==C&&(w(s),_(new Set),b(new Set(s.files.map(e=>e.rel))));let T=e=>_(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n}),E=()=>_(e=>e.size===k.length?new Set:new Set(k.map(e=>e.rel))),D=()=>t?.(`export`),O=async()=>{let t=[...g],n=t.filter(e=>s.files.find(t=>t.rel===e)?.status===`added`),a=n.length?`Restoring will DELETE ${n.length} deployed-only file(s):\n${n.join(`
|
|
2
|
-
`)}\n\n`:``;if(await i(`${a}Discard local edits and restore ${t.length} file(s) from source?`,{title:`Restore from source?`,confirmLabel:`Restore`})){p(!0);try{let n=await r.restore(t),i=n.errors.length?` · ${n.errors.length} error(s): ${n.errors.join(`; `)}`:``;h(`Restored ${n.restored.length}, deleted ${n.deleted.length}${i}`),await u(),e?.()}catch(e){h(e.message)}finally{p(!1)}}};if(c)return(0,S.jsx)(y,{error:c});if(!s)return(0,S.jsx)(o,{});if(!s.deployed)return(0,S.jsxs)(`div`,{className:`empty`,children:[(0,S.jsx)(`div`,{className:`big`,children:`No deployed harness`}),`Nothing to diff against.`]});if(!s.diffable)return(0,S.jsxs)(`div`,{className:`empty`,children:[(0,S.jsx)(`div`,{className:`big`,children:`No drift check for this install`}),`The drift check covers global installs only.`]});let k=s.files.filter(e=>e.status!==`linked`),A=s.files.filter(e=>e.status===`linked`),j=k.filter(e=>e.status===`edited`).length,M=k.filter(e=>e.status===`added`).length,N=k.filter(e=>e.status===`missing`).length,P=e=>b(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n});return(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{className:`h`,children:`Local edits`}),(0,S.jsx)(`p`,{className:`sub`,children:`The agent refines its own deployed files in place. Export them as improvements before any rebuild overwrites them.`})]}),(0,S.jsxs)(`div`,{className:`row gap-10`,children:[(0,S.jsxs)(`button`,{className:`btn ghost`,disabled:f||g.size===0,onClick:O,children:[`Restore`,g.size?` (${g.size})`:``]}),(0,S.jsxs)(`button`,{className:`btn`,disabled:f,onClick:D,children:[(0,S.jsx)(l,{name:`download`}),`Export improvements`]})]})]}),m?(0,S.jsx)(`p`,{className:`sub mb-14`,children:m}):null,A.length?(0,S.jsxs)(`p`,{className:`sub dim mb-14`,title:A.map(e=>e.rel).join(`
|
|
3
|
-
`),children:[A.length,` linked — yours, left alone`]}):null,k.length===0?(0,S.jsxs)(`div`,{className:`empty`,children:[(0,S.jsx)(`div`,{className:`big`,children:`In sync`}),`Deployed harness matches source.`]}):(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`div`,{className:`row between mb-14`,children:[(0,S.jsxs)(`div`,{className:`row gap-10`,children:[(0,S.jsxs)(`span`,{className:`badge`,children:[(0,S.jsx)(`span`,{className:`dot`,style:{background:`var(--warn)`}}),j,` edited`]}),(0,S.jsxs)(`span`,{className:`badge`,children:[(0,S.jsx)(`span`,{className:`dot`,style:{background:`var(--good)`}}),M,` added`]}),N>0&&(0,S.jsxs)(`span`,{className:`badge`,children:[(0,S.jsx)(`span`,{className:`dot`,style:{background:`var(--bad)`}}),N,` missing`]})]}),(0,S.jsxs)(`label`,{className:`row dim`,style:{gap:8,fontSize:12.5,cursor:`pointer`},children:[(0,S.jsx)(`input`,{type:`checkbox`,style:{accentColor:`var(--accent)`},checked:g.size===k.length,onChange:E}),`Select all`]})]}),(0,S.jsx)(`div`,{className:`stack gap-12`,children:k.map(e=>{let t=v.has(e.rel),n=e.status===`added`?`ok`:e.status===`missing`?`bad`:`warn`;return(0,S.jsxs)(`div`,{className:`card diff-file${t?` open`:``}`,children:[(0,S.jsxs)(`div`,{className:`diff-head`,children:[(0,S.jsx)(`input`,{type:`checkbox`,className:`chk`,checked:g.has(e.rel),onChange:()=>T(e.rel),onClick:e=>e.stopPropagation(),"aria-label":`Select ${e.rel}`}),(0,S.jsx)(`span`,{className:`fname`,children:e.rel}),(0,S.jsxs)(`span`,{className:`badge ${n}`,children:[(0,S.jsx)(`span`,{className:`dot`}),e.status]}),(0,S.jsxs)(`span`,{className:`dim mono`,style:{marginLeft:`auto`,fontSize:11},children:[e.diff.length,` lines`]}),(0,S.jsx)(`button`,{className:`iconbtn`,onClick:()=>P(e.rel),style:{transform:t?`rotate(90deg)`:`none`},"aria-label":t?`Collapse ${e.rel}`:`Expand ${e.rel}`,"aria-expanded":t,children:(0,S.jsx)(l,{name:`chevron`})})]}),t&&(0,S.jsx)(`div`,{className:`diff-body`,children:e.diff.map((e,t)=>(0,S.jsx)(`div`,{className:`diff-line ${B(e)}`,children:e},t))})]},e.rel)})})]})]})}function H({group:e,i:t}){let n=e.problems.length===0,[r,i]=(0,x.useState)(!n);return(0,S.jsxs)(`div`,{className:`card check rise ${n?``:`bad`} ${r?`open`:``}`,style:{"--i":t*.6},children:[(0,S.jsxs)(`button`,{className:`check-head`,onClick:()=>i(e=>!e),disabled:n,style:{cursor:n?`default`:`pointer`},"aria-expanded":n?void 0:r,children:[(0,S.jsx)(`span`,{className:`feed-dot ${n?`ok`:`bad`}`,style:{width:9,height:9}}),(0,S.jsx)(`h3`,{children:e.label}),(0,S.jsxs)(`span`,{className:`badge ${n?`ok`:`bad`}`,children:[(0,S.jsx)(`span`,{className:`dot`}),n?`clean`:`${e.problems.length} problem${e.problems.length===1?``:`s`}`]}),!n&&(0,S.jsx)(l,{name:`chevron`,className:`chev glyph`})]}),!n&&r&&(0,S.jsx)(`div`,{className:`check-body`,children:e.problems.map(e=>(0,S.jsxs)(`div`,{className:`problem`,children:[(0,S.jsx)(`span`,{className:`x`,children:`✕`}),(0,S.jsx)(`span`,{children:e})]},e))})]})}function U(){let e=(0,x.useRef)(!1),{data:t,error:n,reload:i,setData:s}=a(()=>r.doctor(e.current),[]);return n?(0,S.jsx)(y,{error:n}):(0,S.jsxs)(`div`,{className:`narrow`,children:[(0,S.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{className:`h`,children:`Doctor`}),(0,S.jsx)(`p`,{className:`sub`,children:`Every check builds each theme in a sandbox and validates the result: token resolution, link integrity, parity, and drift.`})]}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:()=>{e.current=!0,s(null),i()},disabled:!t,children:[(0,S.jsx)(l,{name:`refresh`}),t?`Re-run checks`:`Running…`]})]}),t?(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(`div`,{className:`card pad-md mb-16`,children:(0,S.jsxs)(`div`,{className:`row wrap between gap-12`,children:[(0,S.jsxs)(`div`,{className:`row`,style:{gap:10,flexWrap:`wrap`},children:[(0,S.jsxs)(`span`,{className:`dim mono`,style:{fontSize:12},children:[`validated `,t.themes.length,` theme`,t.themes.length===1?``:`s`]}),t.themes.map(e=>(0,S.jsx)(`span`,{className:`badge`,style:{textTransform:`capitalize`},children:e},e))]}),t.ok?(0,S.jsxs)(`span`,{className:`badge ok`,children:[(0,S.jsx)(`span`,{className:`dot`}),`all clean`]}):(0,S.jsxs)(`span`,{className:`badge bad`,children:[(0,S.jsx)(`span`,{className:`dot`}),t.problems.length,` problem`,t.problems.length===1?``:`s`]})]})}),(0,S.jsx)(`div`,{className:`stack gap-12`,children:t.groups.map((e,t)=>(0,S.jsx)(H,{group:e,i:t},e.label))})]}):(0,S.jsx)(o,{label:`Running every check (builds each theme in a sandbox)…`})]})}function W(){let e=d(),[t,n]=(0,x.useState)(!1),[i,a]=(0,x.useState)(!1),[o,s]=(0,x.useState)(null);return t?(0,S.jsxs)(`p`,{className:`sub`,children:[`Server stopped. You can close this tab and reopen any time with `,(0,S.jsx)(`code`,{children:`geneseed web`}),`.`]}):(0,S.jsxs)(S.Fragment,{children:[o&&(0,S.jsx)(`p`,{className:`sub`,role:`alert`,children:o}),(0,S.jsxs)(`div`,{className:`row`,children:[(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:async()=>{if(await e(`Restart the local Geneseed server? The console reconnects in a moment.`,{title:`Restart the server?`,confirmLabel:`Restart`})){a(!0),s(null);try{await m()}catch(e){s(e.message),a(!1)}}},disabled:i,children:[(0,S.jsx)(l,{name:`refresh`}),i?`Restarting…`:`Restart server`]}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:async()=>{if(await e(`Stop the local Geneseed server? The console goes offline until you start it again.`,{title:`Stop the server?`,confirmLabel:`Stop server`})){s(null);try{await r.shutdown()}catch(e){if(e.status)return s(e.message)}n(!0)}},disabled:i,children:[(0,S.jsx)(l,{name:`x`}),`Stop server`]})]})]})}var G=`https://github.com/Arylmera/Geneseed`,K=`https://github.com/Arylmera`;function q(){let[e,t]=(0,x.useState)(G),[n,i]=(0,x.useState)(!0);return(0,x.useEffect)(()=>{Promise.resolve(r.docsPage?.(`about`)).then(e=>{e?.repo&&(t(e.repo),i(!!e.repo_is_github))}).catch(()=>{})},[]),(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`About`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`Geneseed is a portable, theme-able harness you implant once and use everywhere to grow a disciplined AI coding agent. One canonical source, many voices, MIT-licensed.`}),(0,S.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,S.jsxs)(`a`,{className:`btn ghost`,href:e,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(l,{name:`github`}),n?`Source on GitHub`:`Source repo`]}),n&&(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`a`,{className:`btn ghost`,href:e+`/issues`,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(l,{name:`external`}),`Issues`]}),(0,S.jsxs)(`a`,{className:`btn ghost`,href:e+`/blob/main/LICENSE`,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(l,{name:`external`}),`MIT License`]})]})]})]}),(0,S.jsxs)(`div`,{className:`card pad-lg`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Creator`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[`Geneseed is built by `,(0,S.jsx)(`strong`,{children:`Guillaume Lemer`}),`. It started as a personal, Obsidian-vault-grown agent operating system and was distilled into the repo you are running. Implant it once, and a disciplined agent grows around the same inherited rules, skills, and memory in every repo it follows you into.`]}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`If you find this useful, a star on the repo or an issue with feedback is the best way to help shape what comes next.`}),(0,S.jsx)(`div`,{className:`row wrap gap-10`,children:(0,S.jsxs)(`a`,{className:`btn ghost`,href:K,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(l,{name:`github`}),`@Arylmera on GitHub`]})})]})]})}function J({overview:e,onAction:t,flavour:n,onFlavour:r,accentMode:i,onAccentMode:a,layout:o,onLayout:c}){let u=d(),m=e?.install,g=e?.footprint,_=async e=>{m&&e!==g&&await u(`Rebuild ${m.host} · ${m.scope} with the “${e}” footprint? It rebuilds in place, non-destructive.`,{title:`Change the footprint?`,confirmLabel:`Rebuild`})&&t?.(`install`,{...m,footprint:e})};return(0,S.jsxs)(`div`,{className:`narrow-lg`,children:[(0,S.jsx)(`div`,{className:`head-row mb-18`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{className:`h`,children:`Settings`}),(0,S.jsx)(`p`,{className:`sub`,children:`Console appearance, the footprint of the install you are viewing, machine maintenance (including the update), server control, and about. Each install is managed on the Hosts tab.`})]})}),n&&r&&(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Console direction`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[h.length,` takes on the same data. Pick a direction; it applies instantly and persists across reloads.`]}),i&&a&&(0,S.jsxs)(`div`,{className:`dir-layout`,children:[(0,S.jsx)(`span`,{className:`tick`,id:`dir-accent-label`,children:`Accent`}),(0,S.jsx)(v,{value:i,onChange:a,labelledBy:`dir-accent-label`}),(0,S.jsx)(`span`,{className:`dir-layout-note sub`,role:`status`,"aria-live":`polite`,children:p(i)})]}),o&&c&&(0,S.jsxs)(`div`,{className:`dir-layout`,children:[(0,S.jsx)(`span`,{className:`tick`,id:`dir-layout-label`,children:`Overview view`}),(0,S.jsx)(f,{"aria-labelledby":`dir-layout-label`,children:s.map(e=>(0,S.jsx)(`button`,{className:o===e.id?`on`:``,onClick:()=>c(e.id),"aria-pressed":o===e.id,title:e.tagline,children:e.short},e.id))}),(0,S.jsx)(`span`,{className:`dir-layout-note sub`,role:`status`,"aria-live":`polite`,children:s.find(e=>e.id===o)?.tagline??``})]}),(0,S.jsx)(`div`,{className:`dir-grid`,children:h.map(e=>(0,S.jsxs)(`button`,{className:`dir-tile dir-${e.id} ${n===e.id?`on`:``}`,onClick:()=>r(e.id),"aria-pressed":n===e.id,children:[(0,S.jsxs)(`span`,{className:`dir-thumb`,"aria-hidden":`true`,children:[(0,S.jsx)(`span`,{className:`dir-thumb-rail`}),(0,S.jsx)(`span`,{className:`dir-thumb-bar`}),(0,S.jsx)(`span`,{className:`dir-thumb-bar`,style:{width:`70%`}}),(0,S.jsx)(`span`,{className:`dir-thumb-bar`,style:{width:`52%`}}),(0,S.jsx)(`span`,{className:`dir-thumb-dot`})]}),(0,S.jsxs)(`span`,{className:`dir-meta`,children:[(0,S.jsxs)(`span`,{className:`dir-name`,children:[e.short,n===e.id&&(0,S.jsx)(`span`,{className:`dir-check`,children:`● active`})]}),(0,S.jsx)(`span`,{className:`dir-tag`,children:e.tagline})]})]},e.id))})]}),m&&g&&(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Harness footprint`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[`How much of the Rules `,(0,S.jsx)(`code`,{children:`AGENT.md`}),` carries inline each turn, for the current install (`,(0,S.jsxs)(`code`,{children:[m.host,` · `,m.scope]}),`). A token-cost dial; every Rule stays in force either way. Changing it rebuilds the install in place. `,(0,S.jsx)(`a`,{href:`#/docs/footprint`,children:`Learn more →`})]}),(0,S.jsxs)(`div`,{className:`dir-layout`,children:[(0,S.jsx)(`span`,{className:`tick`,id:`footprint-label`,children:`Footprint`}),(0,S.jsx)(f,{"aria-labelledby":`footprint-label`,children:[`full`,`lean`].map(e=>(0,S.jsx)(`button`,{className:g===e?`on`:``,onClick:()=>_(e),"aria-pressed":g===e,children:e},e))}),(0,S.jsx)(`span`,{className:`dir-layout-note sub`,role:`status`,"aria-live":`polite`,children:g===`lean`?`Lean: terse rule lines + a pointer to the full law file (~40% smaller, lighter context per turn).`:`Full: every Rule’s complete text and rationale inlined (maximum guidance, largest context).`})]})]}),(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Maintenance`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[`Put `,(0,S.jsx)(`code`,{children:`geneseed`}),` on your PATH so it runs from any directory, or remove a global install. Your memory store is always kept. Each runs live in the console.`]}),(0,S.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:()=>t(`update`),children:[(0,S.jsx)(l,{name:`download`}),`Update (git pull + rebuild)`]}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:()=>t(`link`),children:[(0,S.jsx)(l,{name:`external`}),`Add to PATH`]}),(0,S.jsx)(`button`,{className:`btn ghost`,onClick:()=>t(`unlink`),children:`Remove from PATH`}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:async()=>{await u(`Uninstall the global Geneseed harness? Your memory store is kept; everything else this install added is removed.`,{title:`Uninstall Geneseed?`,confirmLabel:`Uninstall`})&&t(`uninstall`)},children:[(0,S.jsx)(l,{name:`clear`}),`Uninstall`]})]})]}),(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Server`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`The console runs a small local server. Leave it running in the background and reopen any time, or stop it when you are done.`}),(0,S.jsx)(W,{})]}),(0,S.jsx)(q,{})]})}function Y({tab:e=`hosts`,overview:t,setup:n,themes:r,onAction:i,onMutated:a,dataRev:o,appearance:s={}}){let c=t?.doctor,l=t?.diff,d={edits:l?u(l):null,doctor:c?c.ok?`clean`:c.problems.length:null};return(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(`div`,{className:`page-head`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h1`,{className:`h`,children:`Installs`}),(0,S.jsx)(`p`,{className:`sub`,children:`Where the harness lives on this machine, and how each copy is built.`})]})}),(0,S.jsx)(b,{page:`installs`,current:e,badges:d,label:`Installs`}),e===`hosts`&&(0,S.jsx)(z,{onAction:i,themes:r,currentTheme:t?.theme,overview:t,setup:n,dataRev:o,onMutated:a}),e===`edits`&&(0,S.jsx)(V,{onMutated:a,onAction:i,dataRev:o}),e===`doctor`&&(0,S.jsx)(U,{}),e===`server`&&(0,S.jsx)(J,{overview:t,onAction:i,...s})]})}export{Y as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{n as e,s as t}from"./sections-BET3c1WT.js";import{i as n,t as r}from"./react-BOF6yL40.js";import{t as i}from"./api-CiXlkbe0.js";import{t as a}from"./drawable-CyLe1gtW.js";import{$ as o,B as s,Dt as c,R as l,St as u,Tt as d,X as f,Y as p,_ as m,_t as h,at as g,bt as _,ct as v,dt as y,et as b,ft as x,gt as S,ht as C,it as w,lt as T,mt as E,nt as D,ot as O,pt as k,q as A,rt as j,st as M,tt as N,ut as P,vt as F,wt as I,yt as L,z as R}from"./index-DQXG_mqo.js";function z(e){return x((e.iterationDuration+e._loopDelay)*e.iterationCount-e._loopDelay)||1e-11}function B(e,t,n,r,i,a){let o=C(e.duration)&&e.duration<=1e-11?n-d:n;t.composition&&T(t,o,1,1,c.AUTO);let s=r?new D(r,e,t,o,!1,i,a):new O(e,t,o);return t.composition&&s.init(!0),y(t,s),k(t,e=>{let n=e._offset+e._delay+e.duration;n>t.iterationDuration&&(t.iterationDuration=n)}),t.duration=z(t),t}var V=0,H=class extends O{constructor(e={}){super(e,null,0),++V,this.id=F(e.id)?V:e.id,this.duration=0,this.labels={};let t=e.defaults,n=u.defaults;this.defaults=t?L(t,n):n,this.composition=P(e.composition,!0),this.onRender=e.onRender||n.onRender;let r=P(e.playbackEase,n.playbackEase);this._ease=r?w(r):null,this.iterationDuration=0}add(e,t,n){let r=S(t),i=S(e);if(r||i){if(this._hasChildren=!0,r){let r=t,i=u.editor&&u.editor.addTimelineChild,a=n&&n.type===`Stagger`&&u.editor,o=E(n)?n:null;if(o||a){let t=g(e),a=this.duration,s=this.iterationDuration,c=r.id,l=0,d=t.length,f=i?i(e,r,this.id,n,d):null,p=o||u.editor.resolveStagger(n.defaultValue);t.forEach(e=>{let n={...f||r};this.duration=a,this.iterationDuration=s,F(c)||(n.id=c+`-`+l);let i=N(this,p(e,l,t,null,this));B(n,this,i,e,l,t),l++})}else{let t=i?i(e,r,this.id,n):r,a=n&&n.type?n.defaultValue:n;B(t,this,N(this,a),e)}}else B(e,this,N(this,t));return this.composition&&this.init(!0),this}}sync(e,t){if(F(e)||e&&F(e.pause))return this;e.pause();let n=+(e.effect?e.effect.getTiming().duration:e.duration);!F(e)&&!F(e.persist)&&(e.persist=!0);let r=u.editor,i=r&&r.addTimelineChild;r&&r.addTimelineSync&&(t=r.addTimelineSync(e,t,this.id),r.addTimelineChild=null);let a=this.add(e,{currentTime:[0,n],duration:n,delay:0,ease:`linear`,playbackEase:`linear`},t);return r&&(r.addTimelineChild=i),a}set(e,t,n){return F(t)?this:(t.duration=d,t.composition=I.replace,this.add(e,t,n))}call(e,t){return F(e)||e&&!E(e)?this:(u.editor&&u.editor.addTimelineCall&&(t=u.editor.addTimelineCall(e,t,this.id)),this.add({duration:0,delay:0,onComplete:()=>e(this)},t))}label(e,t){return F(e)||e&&!h(e)?this:(u.editor&&u.editor.addTimelineLabel&&(t=u.editor.addTimelineLabel(e,t,this.id)),this.labels[e]=N(this,t),this)}remove(e,t){return M(g(e),this,t),this}stretch(e){let t=this.duration;if(t===_(e))return this;let n=e/t,r=this.labels;k(this,e=>e.stretch(e.duration*n));for(let e in r)r[e]*=n;return super.stretch(e)}refresh(){return k(this,e=>{e.refresh&&e.refresh()}),this}revert(){return super.revert(),k(this,e=>e.revert,!0),v(this)}then(e){return super.then(e)}},U=e=>u.editor?u.editor.addTimeline(e):new H(e).init(),W=t(n(),1),G=r(),K=.62,q=(e,t)=>String(e).length*t*K;function J(e,t){let n=0;for(let t of e){if(t.t===``||t.t==null)continue;let e=q(t.t,t.size)/2;n=Math.max(n,Math.hypot(e,t.dy-t.size*.75),Math.hypot(e,t.dy+t.size*.25))}return Math.ceil(n+t)}function Y(e,t,n=0){let r=t.x-e.x,i=t.y-e.y,a=Math.hypot(r,i)||1,o=r/a,s=i/a,c=e.x+o*e.r,l=e.y+s*e.r,u=t.x-o*t.r,d=t.y-s*t.r,f=n*a,p=e=>e.toFixed(1);return`M${p(c)} ${p(l)} C${p(c+o*a*.3-s*f)} ${p(l+s*a*.3+o*f)} ${p(u-o*a*.3-s*f)} ${p(d-s*a*.3+o*f)} ${p(u)} ${p(d)}`}var X=!1,Z=!1,Q=850;function $({hash:e,label:t,part:n,children:r}){return(0,G.jsx)(`g`,{className:`cm-node`,"data-cm":n,role:`button`,tabIndex:0,"aria-label":t,onClick:()=>A(e),onKeyDown:t=>{(t.key===`Enter`||t.key===` `)&&(t.preventDefault(),A(e))},children:r})}function ee({overview:e,dataRev:t}){let{data:n}=s(()=>i.catalog(`laws`),[t],`catalog:laws`),r=n?.items??null,c=(0,W.useRef)(null),l=(0,W.useRef)(!0),u=(0,W.useRef)(null);(0,W.useLayoutEffect)(()=>{let e=c.current;if(!e||X||!p())return;X=!0;let t=t=>[...e.querySelectorAll(t)],n=t(`[data-cm="hub"]`),r=t(`[data-cm="sat"]`),i=t(`[data-cm="gov"]`),s=t(`.cm-edge-gov`),d=t(`.cm-note, .cm-govern-label`),m=a(t(`.cm-edge`));b([...n,...r,...i],{opacity:0,scale:.7}),b([...s,...d],{opacity:0}),b(m,{draw:`0 0`});let h=U({autoplay:!1,defaults:{ease:`outExpo`}}).add(n,{opacity:1,scale:1,duration:450},0).add(m,{draw:`0 1`,duration:380,delay:o(70)},140).add(r,{opacity:1,scale:1,duration:420,delay:o(70)},260).add(s,{opacity:1,duration:300,delay:o(50)},420).add(i,{opacity:1,scale:1,duration:380,delay:o(50)},470).add(d,{opacity:1,duration:300},520);l.current=!1;let g=()=>h.complete(),_=()=>{h.play(),g=f(h,Q),l.current=!0,u.current?.()};if(typeof IntersectionObserver>`u`)return _(),()=>g();let v=new IntersectionObserver(e=>{e.some(e=>e.isIntersecting)&&(v.disconnect(),_())},{threshold:.33});return v.observe(e),()=>{v.disconnect(),l.current=!0,g()}},[]);let d=e?.counts||{},h=R(d),g=[];for(let e of(r||[]).filter(e=>e.tier===`doctrine`)){let t=g.find(t=>t.id===e.pack);t||g.push(t={id:e.pack,on:0}),e.active!==!1&&(t.on+=1)}let _=e?.footprint===`lean`?`lean — first line only`:`full text inlined`,v={x:330,y:165,r:J([{t:`Constitution`,size:17,dy:-12},{t:`${h} rules in force`,size:10,dy:8},{t:_,size:8.5,dy:24}],12)},y={x:126,y:95,r:J([{t:`Ethos`,size:12.5,dy:-7},{t:`${d.ontology??0} sections`,size:10,dy:10}],11)},x={x:560,y:78,r:J([{t:`Dictates`,size:12.5,dy:-6},{t:`${d.laws??0}`,size:13,dy:12}],11)},S={x:560,y:252,r:J([{t:`Doctrines`,size:12.5,dy:-6},{t:`${d.doctrines?.rules??0}`,size:13,dy:12}],11)},C=(e,t,n,r)=>({x:e,y:t,label:n,count:r,r:J([{t:n,size:10.5,dy:-2},{t:`${r}`,size:9,dy:10}],9)}),w=[{...C(812,52,`Skills`,d.skills??0),hash:`#/skills`,from:x},{...C(820,126,`Agents`,d.agents??0),hash:`#/agents`,from:x},{...C(816,232,`Memory`,d.memory??0),hash:`#/section/memory`,from:S},{...C(812,300,`Wiki`,d.wiki??0),hash:`#/section/wiki`,from:S}],T={rx:122,ry:68,from:212,to:112},E=g.map((e,t)=>{let n=(g.length===1?(T.from+T.to)/2:T.from+(T.to-T.from)*t/(g.length-1))*Math.PI/180;return{...e,x:S.x+T.rx*Math.cos(n),y:S.y+T.ry*Math.sin(n),r:J([{t:e.id,size:7.5,dy:-2},{t:`${e.on}`,size:7.5,dy:8}],4)}}),D=E.length;return(0,W.useLayoutEffect)(()=>{let e=c.current;if(!e||!D||Z||!p())return;Z=!0;let t=[...e.querySelectorAll(`.cm-mini > g`)];b(t,{opacity:0,scale:.5});let n=()=>b(t,{opacity:1,scale:1}),r=()=>{u.current=null;let e=j(t,{opacity:1,scale:1,duration:380,delay:o(45,{start:420}),ease:`outExpo`});n=f(e,420+45*D+380)};return l.current?r():u.current=r,()=>{u.current=null,n()}},[D]),(0,G.jsxs)(`svg`,{ref:c,className:`cmap`,viewBox:`0 0 940 350`,role:`group`,"aria-label":`The constitution map`,children:[(0,G.jsx)(`path`,{d:Y(v,y,.05),className:`cm-edge`}),(0,G.jsx)(`path`,{d:Y(v,x,-.07),className:`cm-edge`}),(0,G.jsx)(`path`,{d:Y(v,S,.07),className:`cm-edge`}),w.map(e=>(0,G.jsx)(`path`,{d:Y(e.from,e,.03),className:`cm-edge-gov`},`e-${e.label}`)),(0,G.jsxs)($,{hash:`#/laws`,part:`hub`,label:`Constitution: ${h} rules in force`,children:[(0,G.jsx)(`circle`,{cx:v.x,cy:v.y,r:v.r,className:`cm-hub-disc`}),(0,G.jsx)(`text`,{x:v.x,y:v.y-12,textAnchor:`middle`,className:`cm-hub-name`,children:`Constitution`}),(0,G.jsxs)(`text`,{x:v.x,y:v.y+8,textAnchor:`middle`,className:`cm-hub-num`,children:[h,` rules in force`]}),(0,G.jsx)(`text`,{x:v.x,y:v.y+24,textAnchor:`middle`,className:`cm-note`,children:_})]}),(0,G.jsxs)($,{hash:`#/laws`,part:`sat`,label:`Ethos: ${d.ontology??0} sections`,children:[(0,G.jsx)(`circle`,{cx:y.x,cy:y.y,r:y.r,className:`cm-sat-disc`}),(0,G.jsx)(`text`,{x:y.x,y:y.y-7,textAnchor:`middle`,className:`cm-sat-name`,children:`Ethos`}),(0,G.jsxs)(`text`,{x:y.x,y:y.y+10,textAnchor:`middle`,className:`cm-sat-num`,children:[d.ontology??0,` sections`]})]}),(0,G.jsx)(`text`,{x:y.x,y:y.y+y.r+16,textAnchor:`middle`,className:`cm-note`,children:`how it thinks, not a rule`}),(0,G.jsxs)($,{hash:`#/laws`,part:`sat`,label:`Dictates: ${d.laws??0}, never broken`,children:[(0,G.jsx)(`circle`,{cx:x.x,cy:x.y,r:x.r,className:`cm-sat-disc`}),(0,G.jsx)(`text`,{x:x.x,y:x.y-6,textAnchor:`middle`,className:`cm-sat-name`,children:`Dictates`}),(0,G.jsx)(`text`,{x:x.x,y:x.y+12,textAnchor:`middle`,className:`cm-sat-big`,children:d.laws??0})]}),(0,G.jsx)(`text`,{x:x.x,y:x.y+x.r+16,textAnchor:`middle`,className:`cm-note`,children:`never broken`}),(0,G.jsxs)($,{hash:`#/laws`,part:`sat`,label:`Doctrines: ${d.doctrines?.rules??0} rules chosen at build`,children:[(0,G.jsx)(`circle`,{cx:S.x,cy:S.y,r:S.r,className:`cm-sat-disc`}),(0,G.jsx)(`text`,{x:S.x,y:S.y-6,textAnchor:`middle`,className:`cm-sat-name`,children:`Doctrines`}),(0,G.jsx)(`text`,{x:S.x,y:S.y+12,textAnchor:`middle`,className:`cm-sat-big`,children:d.doctrines?.rules??0})]}),(0,G.jsx)(`text`,{x:S.x+22,y:S.y+S.r+20,className:`cm-note`,children:d.doctrines?`chosen at build · ${d.doctrines.active}/${d.doctrines.total} packs lit`:`chosen at build`}),(0,G.jsx)(`g`,{className:`cm-mini`,children:E.map(e=>(0,G.jsxs)(`g`,{children:[(0,G.jsx)(`circle`,{cx:e.x,cy:e.y,r:e.r,className:`cm-pack-disc`,style:{stroke:m(e.id)}}),(0,G.jsx)(`text`,{x:e.x,y:e.y-2,textAnchor:`middle`,className:`cm-pack-id`,children:e.id}),(0,G.jsx)(`text`,{x:e.x,y:e.y+8,textAnchor:`middle`,style:{fill:m(e.id)},children:e.on})]},e.id))}),(0,G.jsx)(`text`,{x:866,y:16,textAnchor:`middle`,className:`cm-govern-label`,children:`GOVERNS THE HARNESS`}),w.map(e=>(0,G.jsxs)($,{hash:e.hash,part:`gov`,label:`${e.label}: ${e.count}`,children:[(0,G.jsx)(`circle`,{cx:e.x,cy:e.y,r:e.r,className:`cm-gov-disc`}),(0,G.jsx)(`text`,{x:e.x,y:e.y-2,textAnchor:`middle`,className:`cm-gov-name`,children:e.label}),(0,G.jsx)(`text`,{x:e.x,y:e.y+10,textAnchor:`middle`,className:`cm-gov-num`,children:e.count})]},e.label)),(0,G.jsx)(`text`,{x:y.x,y:228,textAnchor:`middle`,className:`cm-note`,children:`tap any node to open its ledger`})]})}function te(){let e=new Date,t=e=>String(e).padStart(2,`0`);return`${e.getFullYear()}-${t(e.getMonth()+1)}-${t(e.getDate())}`}function ne({counts:t}){let n=[{label:e.skills.label,n:t.skills??0,hash:`#/skills`},{label:`Rules in force`,n:R(t),hash:`#/laws`},{label:e.agents.label,n:t.agents??0,hash:`#/agents`},{label:e.memory.label,n:t.memory??0,hash:`#/section/memory`},{label:e.notebook.label,n:t.notebook??0,hash:`#/section/notebook`},{label:e.wiki.label,n:t.wiki??0,hash:`#/section/wiki`},{label:e.config.label,n:t.config??0,hash:`#/section/config`}],r=Math.max(...n.map(e=>e.n),1);return(0,G.jsxs)(`div`,{className:`card pad-lg jr-card`,children:[(0,G.jsxs)(`div`,{className:`card-head`,children:[(0,G.jsx)(`h3`,{children:`Growth rings`}),(0,G.jsx)(`span`,{className:`tick right`,children:`by section`})]}),n.map(e=>(0,G.jsxs)(`button`,{className:`jr-ring`,onClick:()=>A(e.hash),children:[(0,G.jsx)(`span`,{className:`jr-ring-label`,children:e.label}),(0,G.jsx)(`span`,{className:`jr-ring-track`,children:(0,G.jsx)(`span`,{className:`jr-ring-fill`,style:{width:`${e.n/r*100}%`}})}),(0,G.jsx)(`span`,{className:`jr-ring-num`,children:e.n})]},e.label))]})}function re({recent:e,buildEpoch:t}){let n=e?.items||[],r=e?.skipped||[];return(0,G.jsxs)(`div`,{className:`card pad-lg jr-card`,children:[(0,G.jsxs)(`div`,{className:`card-head`,children:[(0,G.jsx)(`h3`,{children:`Freshly grown`}),(0,G.jsx)(`span`,{className:`tick right`,children:`newest`})]}),e?n.length===0?(0,G.jsx)(`p`,{className:`sub`,children:`Nothing here carries a date yet.`}):n.slice(0,5).map(e=>(0,G.jsxs)(`button`,{className:`jr-fresh`,onClick:()=>A(`#/item/${e.type}/${encodeURIComponent(e.name)}`),children:[(0,G.jsx)(`span`,{className:`jr-fresh-kind`,children:e.section}),(0,G.jsx)(`span`,{className:`jr-fresh-name`,children:e.title}),(0,G.jsx)(`span`,{className:`jr-fresh-when`,children:l(e.mtime)})]},`${e.section}:${e.name}`)):(0,G.jsx)(`p`,{className:`sub`,children:`Reading the shelves…`}),r.length>0&&(0,G.jsxs)(`p`,{className:`sub jr-skipped`,children:[`Not dated: `,r.join(`, `),` — too many files to stat on every load.`]}),(0,G.jsxs)(`p`,{className:`jr-care`,children:[t?`Last built ✓ ${l(t)}`:`Never built here`,` ·`,` `,(0,G.jsx)(`button`,{className:`jr-go`,onClick:()=>A(`#/activity`),children:`log →`})]})]})}function ie({overview:e,recent:t,onAction:n,onDirection:r,dataRev:i}){let a=e?.counts||{};return(0,G.jsxs)(G.Fragment,{children:[(0,G.jsxs)(`div`,{className:`head-row jr-head`,children:[(0,G.jsxs)(`div`,{children:[(0,G.jsxs)(`div`,{className:`eyebrow`,children:[`Field journal · `,te()]}),(0,G.jsx)(`h1`,{className:`h`,children:`Today in this harness`})]}),(0,G.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,G.jsx)(`button`,{className:`btn primary`,onClick:()=>n?.(`update`),children:`Update & rebuild`}),(0,G.jsx)(`button`,{className:`btn`,onClick:()=>A(`#/doctor`),children:`Doctor`})]})]}),(0,G.jsxs)(`div`,{className:`jr-row2`,children:[(0,G.jsx)(ne,{counts:a}),(0,G.jsx)(re,{recent:t,buildEpoch:e?.build_epoch})]}),(0,G.jsxs)(`div`,{className:`card pad-lg jr-map`,children:[(0,G.jsxs)(`div`,{className:`card-head`,children:[(0,G.jsx)(`h3`,{children:`The Constitution — and the harness it governs`}),(0,G.jsx)(`button`,{className:`jr-go right`,onClick:()=>A(`#/laws`),children:`open →`})]}),(0,G.jsx)(ee,{overview:e,dataRev:i})]}),(0,G.jsxs)(`p`,{className:`sub jr-others`,children:[`Other views:`,` `,(0,G.jsx)(`button`,{className:`jr-go`,onClick:()=>r?.(`lineage`),children:`Lineage`}),` `,`·`,` `,(0,G.jsx)(`button`,{className:`jr-go`,onClick:()=>r?.(`operator`),children:`Operator`})]})]})}export{ie as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{n as e,s as t,t as n}from"./sections-BET3c1WT.js";import{i as r,t as i}from"./react-BOF6yL40.js";import{t as a}from"./api-CiXlkbe0.js";import{B as o,N as s,S as ee,g as c,h as l,q as u,v as d,x as te}from"./index-DQXG_mqo.js";import{a as ne,c as re,l as f,s as p,t as ie,u as ae}from"./Markdown-iHvBrpRN.js";var m=t(r(),1),h=i();function g({load:e}){let t=String(e||`lazy`).toLowerCase();return(0,h.jsx)(`span`,{className:`mf-load mf-load-${t===`eager`?`ok`:t===`exclude`?`warn`:`muted`}`,children:t})}function _({entries:e}){return e.length?(0,h.jsx)(`table`,{className:`mf-entries`,children:(0,h.jsx)(`tbody`,{children:e.map((e,t)=>{let n=String(e.load).toLowerCase()===`exclude`;return(0,h.jsxs)(`tr`,{children:[(0,h.jsx)(`td`,{className:`mf-path mono ${n?`mf-struck`:``}`,children:e.path||`·`}),(0,h.jsx)(`td`,{className:`mf-load-cell`,children:(0,h.jsx)(g,{load:e.load})}),(0,h.jsx)(`td`,{className:`mf-edesc`,children:e.description||``})]},`${e.path||t}-${t}`)})})}):null}function v({wiki:e}){let t=Array.isArray(e.entries)?e.entries:[],n=Array.isArray(e.protected)?e.protected:[];return(0,h.jsxs)(`div`,{className:`mf-vault`,children:[(0,h.jsxs)(`div`,{className:`mf-vault-head`,children:[(0,h.jsx)(`div`,{className:`mf-vault-name`,children:e.name||`wiki`}),e.path?(0,h.jsx)(`code`,{className:`mf-vault-path mono`,children:e.path}):null]}),e.description?(0,h.jsx)(`p`,{className:`mf-vault-desc`,children:e.description}):null,(0,h.jsxs)(`div`,{className:`mf-roles`,children:[e.conventions?(0,h.jsxs)(`span`,{className:`mf-role`,children:[(0,h.jsx)(s,{name:`skill`,className:`glyph`}),` conventions: `,e.conventions]}):null,e.inbox?(0,h.jsxs)(`span`,{className:`mf-role`,children:[(0,h.jsx)(s,{name:`notebook`,className:`glyph`}),` inbox: `,e.inbox]}):null,n.map(e=>(0,h.jsxs)(`span`,{className:`mf-role mf-role-danger`,children:[(0,h.jsx)(s,{name:`law`,className:`glyph`}),` protected: `,e]},e))]}),(0,h.jsx)(_,{entries:t})]})}function y({body:e}){let[t,n]=(0,m.useState)(!1);return e?(0,h.jsxs)(`div`,{className:`mf-raw`,children:[(0,h.jsxs)(`button`,{className:`mf-raw-toggle`,onClick:()=>n(e=>!e),children:[(0,h.jsx)(s,{name:`chevron`,className:`glyph mf-caret ${t?`on`:``}`}),`Raw source`]}),t?(0,h.jsx)(`pre`,{className:`mf-raw-pre`,children:e.replace(/^```json\n|\n```$/g,``)}):null]}):null}function oe({manifest:e,body:t,name:n}){if(!e)return(0,h.jsx)(`pre`,{className:`mf-raw-pre`,children:(t||``).replace(/^```json\n|\n```$/g,``)});if(e.kind===`wiki`){let n=e.wikis||[];return n.length?(0,h.jsxs)(`div`,{className:`mf-doc`,children:[n.map((e,t)=>(0,h.jsx)(v,{wiki:e},e.name||t)),(0,h.jsx)(y,{body:t})]}):(0,h.jsxs)(`div`,{className:`mf-empty`,children:[(0,h.jsx)(`div`,{className:`mf-empty-title`,children:`No wiki declared yet`}),(0,h.jsxs)(`p`,{children:[`A wiki is your machine-wide knowledge base — an Obsidian vault or any folder of linked markdown the agent reads from and writes back to. Declare one in`,` `,(0,h.jsx)(`code`,{className:`mono`,children:`geneseed-wiki.jsonc`}),` to switch it on.`]}),(0,h.jsx)(`a`,{className:`btn ghost sm`,href:`#/docs/wiki`,children:`How to configure a wiki`}),(0,h.jsx)(y,{body:t})]})}let r=e.context||[];return r.length?(0,h.jsxs)(`div`,{className:`mf-doc`,children:[(0,h.jsx)(_,{entries:r}),(0,h.jsx)(y,{body:t})]}):(0,h.jsxs)(`div`,{className:`mf-empty`,children:[(0,h.jsx)(`div`,{className:`mf-empty-title`,children:`No project context declared`}),(0,h.jsxs)(`p`,{children:[`Point the agent at the docs for this project by adding entries to`,` `,(0,h.jsx)(`code`,{className:`mono`,children:n||`context.json`}),` — each with a`,` `,(0,h.jsx)(`code`,{className:`mono`,children:`path`}),`, a `,(0,h.jsx)(`code`,{className:`mono`,children:`load`}),` mode (eager or lazy), and a description.`]}),(0,h.jsx)(y,{body:t})]})}var b={fill:`none`,stroke:`currentColor`,strokeWidth:2,strokeLinecap:`round`,strokeLinejoin:`round`},x={advocate:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M16 50h14M23 50V14`}),(0,h.jsx)(`path`,{className:`ag-wave ag-f`,d:`M23 15h20l-5 7.5 5 7.5H23z`}),(0,h.jsx)(`path`,{className:`ag-call`,d:`M47 38a6 6 0 0 1 0 8M51 35a11 11 0 0 1 0 14`})]}),architect:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`rect`,{x:`14`,y:`14`,width:`36`,height:`32`,rx:`2`,opacity:`.3`}),(0,h.jsx)(`path`,{className:`ag-draw`,pathLength:`100`,d:`M20 40V22h12v9h12v9z`}),(0,h.jsx)(`path`,{className:`ag-draw ag-late`,pathLength:`100`,d:`M32 31v9`}),(0,h.jsx)(`path`,{d:`M14 52h36M14 50v4M50 50v4`,opacity:`.5`})]}),developer:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`rect`,{className:`ag-f`,x:`10`,y:`14`,width:`44`,height:`36`,rx:`4`}),(0,h.jsx)(`path`,{d:`M10 22h44`,opacity:`.5`}),(0,h.jsx)(`circle`,{cx:`15`,cy:`18`,r:`1`}),(0,h.jsx)(`circle`,{cx:`19`,cy:`18`,r:`1`}),(0,h.jsx)(`path`,{className:`ag-nudge-l`,d:`M24 30l-6 6 6 6`}),(0,h.jsx)(`path`,{className:`ag-nudge-r`,d:`M40 30l6 6-6 6`}),(0,h.jsx)(`path`,{className:`ag-blink`,d:`M30 42h5`})]}),docs:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{className:`ag-f`,d:`M16 10h22l8 8v36H16z`}),(0,h.jsx)(`path`,{d:`M38 10v8h8`,opacity:`.5`}),(0,h.jsx)(`path`,{className:`ag-draw`,pathLength:`100`,d:`M21 26h18`}),(0,h.jsx)(`path`,{className:`ag-draw ag-late`,pathLength:`100`,d:`M21 33h18`}),(0,h.jsx)(`path`,{className:`ag-draw ag-later`,pathLength:`100`,d:`M21 40h11`}),(0,h.jsx)(`g`,{className:`ag-write`,children:(0,h.jsx)(`path`,{d:`M40 44l12-20 3 2-12 20-4 1z`})})]}),empiricist:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M12 12v40h40`,opacity:`.5`}),(0,h.jsx)(`rect`,{className:`ag-rise ag-f`,x:`18`,y:`36`,width:`6`,height:`14`}),(0,h.jsx)(`rect`,{className:`ag-rise ag-late ag-f`,x:`29`,y:`28`,width:`6`,height:`22`}),(0,h.jsx)(`rect`,{className:`ag-rise ag-later ag-f`,x:`40`,y:`20`,width:`6`,height:`30`}),(0,h.jsx)(`path`,{className:`ag-draw`,pathLength:`100`,d:`M16 34l12-8 10 3 12-14`})]}),explorer:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`circle`,{cx:`32`,cy:`32`,r:`18`,opacity:`.5`}),(0,h.jsx)(`path`,{d:`M32 10v4M32 50v4M10 32h4M50 32h4`}),(0,h.jsxs)(`g`,{className:`ag-search`,children:[(0,h.jsx)(`path`,{className:`ag-f`,d:`M32 18l5 14h-10z`}),(0,h.jsx)(`path`,{d:`M32 18l5 14-5 14-5-14z`})]}),(0,h.jsx)(`circle`,{cx:`32`,cy:`32`,r:`2`})]}),framer:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`g`,{className:`ag-frame`,children:(0,h.jsx)(`path`,{d:`M12 22V12h10M42 12h10v10M52 42v10H42M22 52H12V42`})}),(0,h.jsx)(`circle`,{className:`ag-pulse`,cx:`32`,cy:`32`,r:`7`,opacity:`.6`}),(0,h.jsx)(`path`,{d:`M32 22v6M32 36v6M22 32h6M36 32h6`,opacity:`.6`}),(0,h.jsx)(`circle`,{cx:`32`,cy:`32`,r:`1.5`})]}),historian:(0,h.jsxs)(`g`,{className:`ag-turn`,children:[(0,h.jsx)(`path`,{d:`M20 12h24M20 52h24`}),(0,h.jsx)(`path`,{d:`M22 12c0 12 20 12 20 20s-20 8-20 20M42 12c0 12-20 12-20 20s20 8 20 20`}),(0,h.jsx)(`path`,{className:`ag-drain ag-f`,d:`M25 17h14c-1 6-5 9-7 11-2-2-6-5-7-11z`}),(0,h.jsx)(`path`,{className:`ag-fill ag-f`,d:`M24 49h16c-1-5-5-8-8-9-3 1-7 4-8 9z`})]}),operator:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M12 42a20 20 0 0 1 40 0`,opacity:`.4`}),(0,h.jsx)(`path`,{className:`ag-f`,d:`M40 24a20 20 0 0 1 12 18`,strokeWidth:`4`,opacity:`.7`}),(0,h.jsx)(`path`,{d:`M16 30l3 2M32 22v4M48 30l-3 2`,opacity:`.6`}),(0,h.jsx)(`g`,{className:`ag-gauge`,children:(0,h.jsx)(`path`,{d:`M32 42l10-13`})}),(0,h.jsx)(`circle`,{cx:`32`,cy:`42`,r:`3`}),(0,h.jsx)(`path`,{d:`M22 50h20`,opacity:`.5`})]}),pragmatist:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M32 14v36M22 50h20`}),(0,h.jsx)(`circle`,{cx:`32`,cy:`14`,r:`2`}),(0,h.jsxs)(`g`,{className:`ag-tilt`,children:[(0,h.jsx)(`path`,{d:`M14 18h36`}),(0,h.jsx)(`path`,{className:`ag-f`,d:`M14 18l-5 12h10zM50 18l-5 12h10z`})]})]}),"memory-curator":(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`rect`,{className:`ag-rise ag-f`,x:`17`,y:`16`,width:`14`,height:`20`,rx:`1`}),(0,h.jsx)(`rect`,{className:`ag-rise ag-late ag-f`,x:`25`,y:`12`,width:`14`,height:`24`,rx:`1`}),(0,h.jsx)(`rect`,{className:`ag-rise ag-later ag-f`,x:`33`,y:`18`,width:`14`,height:`18`,rx:`1`}),(0,h.jsx)(`path`,{d:`M12 32h40v16a2 2 0 0 1-2 2H14a2 2 0 0 1-2-2z`}),(0,h.jsx)(`path`,{d:`M26 40h12`,opacity:`.6`})]}),researcher:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`circle`,{className:`ag-f`,cx:`30`,cy:`34`,r:`16`}),(0,h.jsx)(`path`,{d:`M14 34h32M30 18c-6 5-6 27 0 32`,opacity:`.5`}),(0,h.jsx)(`ellipse`,{className:`ag-spin`,cx:`30`,cy:`34`,rx:`7`,ry:`16`}),(0,h.jsx)(`g`,{className:`ag-orbit`,children:(0,h.jsx)(`circle`,{cx:`50`,cy:`14`,r:`3`})})]}),reviewer:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M12 18h30M12 26h40M12 34h24M12 42h34`,opacity:`.4`}),(0,h.jsx)(`path`,{className:`ag-mark`,d:`M42 30l3 3 6-6`}),(0,h.jsxs)(`g`,{className:`ag-sweep`,children:[(0,h.jsx)(`circle`,{className:`ag-f`,cx:`22`,cy:`30`,r:`9`}),(0,h.jsx)(`path`,{d:`M29 37l8 8`,strokeWidth:`3`})]})]}),performance:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M26 10h8M30 10v6M44 18l3-3`}),(0,h.jsx)(`circle`,{className:`ag-f`,cx:`30`,cy:`34`,r:`18`}),(0,h.jsx)(`path`,{d:`M30 19v3M45 34h-3M30 49v-3M15 34h3`,opacity:`.6`}),(0,h.jsx)(`g`,{className:`ag-orbit`,children:(0,h.jsx)(`path`,{d:`M30 34V22`})}),(0,h.jsx)(`circle`,{cx:`30`,cy:`34`,r:`2`})]}),security:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{className:`ag-ripple`,d:`M32 8l18 6v13c0 12-8 21-18 26-10-5-18-14-18-26V14z`}),(0,h.jsx)(`path`,{className:`ag-f`,d:`M32 8l18 6v13c0 12-8 21-18 26-10-5-18-14-18-26V14z`}),(0,h.jsx)(`path`,{className:`ag-draw`,pathLength:`100`,d:`M24 31l6 6 11-11`})]}),skeptic:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{className:`ag-f`,d:`M12 14h40v28H30l-10 8v-8h-8z`}),(0,h.jsxs)(`g`,{className:`ag-lean`,children:[(0,h.jsx)(`path`,{d:`M27 23a5 5 0 1 1 7 4.5c-1.5.8-2 2-2 3.5v1`}),(0,h.jsx)(`circle`,{cx:`32`,cy:`36`,r:`1.2`})]})]}),steward:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M12 52h40`,opacity:`.5`}),(0,h.jsx)(`path`,{d:`M22 52c2-3 6-4 10-4s8 1 10 4`,opacity:`.4`}),(0,h.jsxs)(`g`,{className:`ag-grow`,children:[(0,h.jsx)(`path`,{d:`M32 50V26`}),(0,h.jsx)(`path`,{className:`ag-sway ag-f`,d:`M32 32c0-9 6-14 15-14 0 9-6 14-15 14z`}),(0,h.jsx)(`path`,{className:`ag-sway ag-late ag-f`,d:`M32 38c0-7-5-11-12-11 0 7 5 11 12 11z`})]})]}),tester:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{d:`M26 10h12M28 10v14L15 48a3 3 0 0 0 2.6 4.5h28.8A3 3 0 0 0 49 48L36 24V10`}),(0,h.jsx)(`path`,{className:`ag-f ag-slosh`,d:`M20 40h24l4.5 8.5H15.5z`}),(0,h.jsx)(`circle`,{className:`ag-bubble`,cx:`28`,cy:`44`,r:`2`}),(0,h.jsx)(`circle`,{className:`ag-bubble ag-late`,cx:`35`,cy:`46`,r:`1.5`}),(0,h.jsx)(`circle`,{className:`ag-bubble ag-later`,cx:`31`,cy:`42`,r:`1`})]}),"user-advocate":(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`circle`,{cx:`24`,cy:`20`,r:`6`}),(0,h.jsx)(`path`,{d:`M12 50c0-9 5-15 12-15 4 0 7 1.5 9 4`}),(0,h.jsx)(`path`,{className:`ag-beat ag-f`,d:`M44 52s-10-6-10-12.5a5 5 0 0 1 10-1.5 5 5 0 0 1 10 1.5C54 46 44 52 44 52z`}),(0,h.jsx)(`path`,{className:`ag-twinkle`,d:`M48 22v4M46 24h4`})]}),visionary:(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`g`,{className:`ag-rays`,opacity:`.5`,children:(0,h.jsx)(`path`,{d:`M32 6v6M32 52v6M6 32h6M52 32h6M13.6 13.6l4.2 4.2M46.2 46.2l4.2 4.2M13.6 50.4l4.2-4.2M46.2 17.8l4.2-4.2`})}),(0,h.jsx)(`path`,{className:`ag-f ag-pulse`,d:`M32 16l4.7 10.4 11.3 1.2-8.5 7.6 2.4 11.1L32 40.6l-9.9 5.7 2.4-11.1-8.5-7.6 11.3-1.2z`}),(0,h.jsx)(`path`,{className:`ag-twinkle`,d:`M50 8v6M47 11h6`})]})},S=(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(`path`,{className:`ag-f`,d:`M32 12l17 10v20L32 52 15 42V22z`}),(0,h.jsx)(`circle`,{className:`ag-pulse`,cx:`32`,cy:`32`,r:`6`})]});function se({name:e,size:t=64}){return(0,h.jsxs)(`svg`,{className:`agent-glyph`,viewBox:`0 0 64 64`,width:t,height:t,"aria-hidden":`true`,...b,children:[(0,h.jsx)(`circle`,{className:`ag-disc`,cx:`32`,cy:`32`,r:`31`}),(0,h.jsx)(`circle`,{className:`ag-ring`,cx:`32`,cy:`32`,r:`31`,strokeWidth:`1`,strokeDasharray:`2 7`}),x[e]||S]})}function C(e,t){return e===`memory`?`memory/${t}`:e===`notebook`?`notebook/${t}`:e===`wiki`?`geneseed-wiki.jsonc`:e===`config`?t:`${e}/${t}.md`}function w({section:t,source:n}){return(0,h.jsxs)(`div`,{className:`lib-doc-empty`,children:[(0,h.jsx)(s,{name:e[t].icon,className:`glyph`}),(0,h.jsxs)(`span`,{children:[`This entry is part of the `,e[t].label.toLowerCase(),` convention; see`,` `,(0,h.jsx)(`code`,{className:`mono`,children:n}),`. It has no standalone per-entry document.`]})]})}var T=(e,t)=>t||(e&&n.includes(e)?e:n[0]),E=encodeURIComponent;function D(e){let t=e=>l[e.klass]?e.klass:`personal`,n=c.flatMap(n=>e.filter(e=>t(e)===n).map(e=>({...e,cat:n,group:l[n].label,groupC:l[n].c})));return{rows:n,cats:c.map(e=>({key:e,label:l[e].label,c:l[e].c,n:n.filter(t=>t.cat===e).length})).filter(e=>e.n>0)}}function O({overview:t,section:r,selected:i,dataRev:s,lock:c,base:g,onRulesChanged:_}){let v=ee(),[y,b]=(0,m.useState)(()=>T(r,c)),[x,S]=(0,m.useState)(``),[O,k]=(0,m.useState)(`all`),[ce,A]=(0,m.useState)(``),[j,M]=(0,m.useState)(r);if(r!==j){M(r);let e=T(r,c);e!==y&&(b(e),S(``),k(`all`))}let{data:N,error:le,reload:P}=o(()=>a.catalog(y),[y,s],`catalog`),F=N?.section===y&&N?.items||[],I=y===`skills`,L=I?D(F):null,R=i||(I?L.rows[0]:F[0])?.name||null,z=R?F.find(e=>e.name===R):null,B=z?.type||e[y].type,{data:V,error:H}=o(()=>R?a.item(B,R):Promise.resolve(null),[y,R,B,s]),U=ce||le||H,ue=R?{name:R,title:V?.title||R,desc:V?.desc||``}:null,W=z||ue,G=t?.counts||{},K=I?L.rows.filter(e=>O===`all`||e.cat===O):F,q=I?1/0:50,J=x.trim().toLowerCase(),Y=J?f(K,J):K.slice(0,q),de=!J&&O===`all`&&R&&!Y.some(e=>e.name===R)?[...Y,...F.filter(e=>e.name===R)]:Y,fe=t=>g?`${g}/${E(t.name)}`:`#/item/${t.type||e[y].type}/${E(t.name)}`,pe=async()=>{let e=W?.name;if(e&&await v(`Forget the memory fact "${e}"? It leaves the index and moves to memory/archive/ (geneseed memory rm --archived --purge deletes it for good).`,{title:`Forget this fact?`,confirmLabel:`Forget`})){A(``);try{await a.memoryDelete(e)}catch(t){A(`Could not forget "${e}": ${t.message}`);return}u(g||`#/section/memory`),P()}},me=async()=>{let e=W?.name;if(e&&await v(`Promote "${e}" into a standing rule? It is appended to user-rules.md as a trial rule (a month of probation), and the memory fact moves to memory/archive/ so the lesson isn't loaded twice.`,{title:`Promote to a rule?`,confirmLabel:`Promote`})){A(``);try{let t=await a.rules();await a.rulesPromote({name:e,fingerprint:t.fingerprint,delete_memory:!0}),d(),_?.(),u(`#/personal/rules`)}catch(e){A(`Could not promote: ${e.message}`),P()}}},X=n.reduce((e,t)=>e+(G[t]??0),0),he=X-(G.skills??0)-(G.agents??0),Z=e=>`${X?e/X*100:0}%`,ge=V?.status||W?.status,Q=y===`skills`?l[z?.klass]:null,$=e[y].label;return(0,h.jsxs)(h.Fragment,{children:[U?(0,h.jsx)(te,{error:U,style:{margin:`0 0 12px`}}):null,(0,h.jsxs)(`div`,{className:`library${c?` locked`:``}`,children:[c?null:(0,h.jsxs)(`aside`,{className:`lib-kinds`,"aria-label":`Library kinds`,children:[(0,h.jsxs)(`div`,{className:`lib-title`,children:[(0,h.jsx)(`h1`,{className:`h`,children:`Library`}),(0,h.jsx)(`span`,{className:`dim`,children:`What the agent knows`})]}),(0,h.jsxs)(`div`,{className:`stackbar thin`,"aria-hidden":`true`,children:[(0,h.jsx)(`span`,{className:`sb-invariants`,style:{width:Z(G.skills??0)}}),(0,h.jsx)(`span`,{className:`sb-doctrines`,style:{width:Z(G.agents??0)}}),(0,h.jsx)(`span`,{className:`sb-rest`,style:{width:Z(he)}})]}),(0,h.jsx)(`nav`,{className:`kind-list`,"aria-label":`Kinds`,children:n.map(t=>(0,h.jsxs)(m.Fragment,{children:[(0,h.jsxs)(`a`,{href:`#/section/${t}`,className:y===t?`on`:``,"aria-current":y===t?`page`:void 0,children:[e[t].label,(0,h.jsx)(`span`,{className:`mono dim`,children:G[t]??``})]}),t===y&&I&&(0,h.jsx)(ne,{label:`Skill types`,total:F.length,cats:L.cats,cat:O,onChange:k})]},t))})]}),(0,h.jsxs)(re,{label:$,count:J?`${Y.length} of ${K.length}`:K.length,q:x,onQ:S,matched:Y.length,inView:[y,i],children:[(0,h.jsx)(p,{rows:de,activeName:W?.name,hrefOf:fe}),!J&&F.length>q&&(0,h.jsxs)(`div`,{className:`lib-more`,children:[`Showing `,q,` of `,F.length,`; type to search the rest.`]}),N?.section===y&&F.length===0&&(0,h.jsxs)(`div`,{className:`empty`,style:{padding:32},children:[(0,h.jsx)(`div`,{className:`big`,children:`Nothing here yet`}),`Once the harness produces entries they appear here.`]})]}),(0,h.jsx)(`article`,{className:`lib-reader`,"aria-label":`Entry`,children:W?(0,h.jsxs)(h.Fragment,{children:[(0,h.jsxs)(`div`,{className:`reader-tags`,children:[(0,h.jsx)(`span`,{className:`tag acc`,children:$.replace(/s$/,``)}),Q?(0,h.jsx)(`span`,{className:`tag`,children:Q.label}):null,(0,h.jsx)(ae,{status:ge})]}),(0,h.jsxs)(`div`,{className:`reader-head`,children:[(0,h.jsx)(`h2`,{className:`reader-title`,children:V?.title||W.title||W.name}),y===`agents`?(0,h.jsx)(se,{name:W.name}):null]}),(V?.desc||W.desc)&&(0,h.jsx)(`p`,{className:`reader-lede`,children:V?.desc||W.desc}),(0,h.jsx)(`p`,{className:`mono dim reader-src`,children:V?.source||W.source||C(y,W.name)}),y===`memory`&&W.name!==`MEMORY`&&W.name!==`README`&&(0,h.jsxs)(`div`,{className:`row gap-8`,children:[(0,h.jsx)(`button`,{type:`button`,className:`btn ghost sm`,onClick:me,title:`Turn this lesson into a standing trial rule in user-rules.md`,children:`Promote to rule`}),(0,h.jsx)(`button`,{type:`button`,className:`btn ghost sm`,onClick:pe,children:`Forget this fact`})]}),(0,h.jsx)(`hr`,{className:`hr`}),W?.kind===`manifest`||V?.manifest!==void 0?V?(0,h.jsx)(oe,{manifest:V.manifest,body:V.body,name:W.name}):(0,h.jsx)(`p`,{className:`sub`,children:`Loading…`}):V?.body?(0,h.jsx)(`div`,{className:`lib-doc detail-doc`,children:(0,h.jsx)(ie,{body:V.body,links:V.links||[]})}):V===null&&R?(0,h.jsx)(`p`,{className:`sub`,children:`Loading…`}):(0,h.jsx)(w,{section:y,source:C(y,W.name)})]}):(0,h.jsxs)(`div`,{className:`empty`,children:[(0,h.jsx)(`div`,{className:`big`,children:`Select an entry`}),`Pick something from the list to read it.`]})})]})]})}export{O as default,D as splitSkills};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{B as i,C as a,G as o,K as s,x as c}from"./index-DQXG_mqo.js";import{t as l}from"./usePoll-NSTzLOF4.js";import{a as u,c as d,l as f,o as p,s as m,t as h}from"./Markdown-iHvBrpRN.js";var g=e(t(),1),_={x:260,y:190},v=110,y=28,b=14,x=44,S=e=>e*Math.PI/180,C=e=>Math.round(e*10)/10,w=(e,t=v,n=_)=>({x:C(n.x+t*Math.cos(S(e))),y:C(n.y+t*Math.sin(S(e)))}),T=e=>e/v*(180/Math.PI)+3,E=(e,t,n,r=0)=>`M${t.x},${t.y} A${e},${e} 0 ${r} 1 ${n.x},${n.y}`,D=C(w(205).x-6),O=e=>e.length*6.4,k=e=>({x:e.x-O(e.name)/2,y:e.y-7,w:O(e.name),h:14}),A=(e,t)=>e.x<t.x+t.w&&t.x<e.x+e.w&&e.y<t.y+t.h&&t.y<e.y+e.h,j=(e,t)=>e.some((n,r)=>[...e.slice(r+1),...t.filter(e=>!e.gate)].some(e=>A(k(n),k(e))));function M(e){return e?.gate===`human`?e.gateOn?.length?`Human gate on ${e.gateOn.join(`, `)}`:`Human gate`:null}function N(e,t=[]){let n=e=>t.find(t=>t.name===e),r=e=>n(e)?.effect??null,i=e=>M(n(e)),a=e.loops||[],o=a.find(e=>e.iteration);if(!o||o.nodes.length>8)return P(e,r,i);let s=Math.max(...e.nodes.map(e=>a.filter(t=>t.nodes.includes(e)).length)),c=a.filter(e=>e!==o);if(s>3||c.some(e=>!e.nodes.every(e=>o.nodes.includes(e))))return P(e,r,i);let l=o.nodes[0],u=new Set(e.edges.filter(e=>e.to===l).map(e=>e.from)),d=new Map;for(let e of[...c].sort((e,t)=>e.nodes.length-t.nodes.length))for(let t of e.nodes.slice(1))t!==l&&!u.has(t)&&!d.has(t)&&d.set(t,e);let f=o.nodes.filter(e=>!d.has(e));if(f.length<2||c.some(e=>d.has(e.nodes[0])))return P(e,r,i);let p=360/f.length,m=f.map((e,t)=>({name:e,a:-90+t*p,r:y})),h=m.findIndex(e=>r(e.name)===`mutate`);h>=0&&m.splice(h,0,{name:`validate`,a:m[h].a-p/2,r:b,gate:!0});let g=m.map(e=>({name:e.name,...w(e.a),r:e.r,effect:e.gate?null:r(e.name),gate:!!e.gate,inner:!1,human:e.gate?null:i(e.name)})),S=m.map((e,t)=>{let n=m[(t+1)%m.length],r=(t+1===m.length?n.a+360:n.a)-T(n.r)-2,i=e.a+T(e.r);return{d:E(v,w(i),w(r),+(r-i>180)),kind:`ring`}}),D=[],k=new Map;for(let e of c)k.set(e.nodes[0],[...k.get(e.nodes[0])||[],e]);for(let[e,t]of k){let n=m.find(t=>t.name===e),a=w(n.a),o=t.length>1;t.sort((e,t)=>e.nodes.length-t.nodes.length).forEach((e,t)=>{let s=w(n.a+(o?t?18:-18:0),v+(o?54:44)),c=Math.atan2(s.y-a.y,s.x-a.x)*(180/Math.PI),l=e.nodes.filter(t=>d.get(t)===e),u=e=>l.map((t,n)=>({name:t,...w(c+(n-(l.length-1)/2)*e,x,s)})),f=105;for(;f<150&&j(u(f),g);)f+=5;u(f).forEach(({name:e,...t})=>{g.push({name:e,...t,r:y,effect:r(e),gate:!1,inner:!0,human:i(e)})});let p=c+180;S.push({d:E(x,w(p+42,x,s),w(p+138,x,s)),kind:`inner`}),S.push({d:E(x,w(p+222,x,s),w(p+318,x,s)),kind:`inner`});let m=`${e.nodes.join(e.nodes.length===2?` ⇄ `:` → `)} · max ${e.max}`,h={lx:s.x,ly:s.y+x+20,anchor:`middle`};if(o){let e=s.x>=_.x,t=Math.max(x,...l.map(e=>{let t=g.find(t=>t.name===e);return Math.abs(t.x-s.x)+y}));h={lx:C(s.x+(e?t+8:-t-8)),ly:C(s.y+4),anchor:e?`start`:`end`}}D.push({loop:e.name,cx:s.x,cy:s.y,r:x,label:m,...h})})}let A=w(205).y,N=e.nodes.filter(e=>!o.nodes.includes(e)),F=N.map((e,t)=>({name:e,x:40,y:C(A-44*(N.length-1-t)),human:i(e)})),I=e.edges.find(e=>e.to===`$close`)?.from,L=g.find(e=>e.name===I),R=L?{from:I,x:L.x+200,y:L.y-30,d:`M${L.x+y},${L.y-6} C${L.x+90},${L.y-40} ${L.x+170},${L.y-40} ${L.x+200},${L.y-30}`}:null,z=Math.max(540,...g.map(e=>e.x+e.r+8),...D.map(e=>e.cx+e.r+8),...D.map(e=>e.anchor===`start`?e.lx+O(e.label)+8:e.lx+O(e.label)/2+8)),B=Math.max(300,...g.map(e=>e.y+e.r+12),...D.map(e=>Math.max(e.cy+e.r,e.ly)+12));return{mode:`ring`,width:Math.ceil(z),height:Math.ceil(B),center:{x:_.x,y:_.y,r:v},nodes:g,arcs:S,inner:D,entry:F,exit:R}}function P(e,t,n){let r=e.loops||[],i=e=>36+16*r.filter(t=>t!==e&&t.nodes.every(t=>e.nodes.includes(t))).length,a=Math.max(y,...r.map(i))+30,o=new Map(e.nodes.map((e,t)=>[e,60+t*100])),s=e.nodes.map(e=>({name:e,x:o.get(e),y:a,r:y,effect:t(e),gate:!1,inner:!1,human:n(e)})),c=e.nodes.slice(1).map((t,n)=>({d:`M${o.get(e.nodes[n])+y},${a} L${o.get(t)-y-4},${a}`,kind:`flow`})),l=r.map(e=>{let t=i(e),n=Math.min(...e.nodes.map(e=>o.get(e))),r=Math.max(...e.nodes.map(e=>o.get(e))),s={x:n-t,y:a-t,w:r-n+2*t,h:2*t};return c.push({d:`M${r},${s.y+s.h} L${n+4},${s.y+s.h}`,kind:`flow`}),{loop:e.name,label:`${e.name} · max ${e.max}`,box:s}});return{mode:`flow`,width:60+e.nodes.length*100,height:2*a,center:null,nodes:s,arcs:c,inner:l,entry:[],exit:null}}var F=n();function I({x:e,y:t,label:n}){return(0,F.jsxs)(`g`,{className:`lr-human`,children:[(0,F.jsx)(`title`,{children:n}),(0,F.jsx)(`circle`,{cx:e,cy:t,r:`9`}),(0,F.jsx)(`circle`,{cx:e,cy:t-2.4,r:`2.6`,className:`lr-human-fig`}),(0,F.jsx)(`path`,{d:`M${e-4.6},${t+5.6} a4.6,4.6 0 0 1 9.2,0 Z`,className:`lr-human-fig`})]})}function L({graph:e,bricks:t,onSelect:n,highlight:r}){let i=N(e,t),a=(e.loops||[]).find(e=>e.iteration),o=e=>t=>{(t.type===`click`||t.key===`Enter`||t.key===` `)&&(t.preventDefault(),n?.(e))};return(0,F.jsxs)(`svg`,{className:`loop-ring`,viewBox:`0 0 ${i.width} ${i.height}`,role:`img`,"aria-label":`${e.name} loop: ${e.nodes.join(`, `)}`,children:[(0,F.jsx)(`defs`,{children:[`ring`,`inner`,`flow`].map(e=>(0,F.jsx)(`marker`,{id:`lr-arrow-${e}`,markerWidth:`10`,markerHeight:`10`,refX:`7`,refY:`4`,orient:`auto`,children:(0,F.jsx)(`path`,{d:`M0,0 L8,4 L0,8 Z`,className:`lr-head-${e}`})},e))}),i.mode===`ring`&&i.inner.map(e=>(0,F.jsxs)(`g`,{children:[(0,F.jsx)(`circle`,{cx:e.cx,cy:e.cy,r:e.r,className:`lr-inner`}),(0,F.jsx)(`text`,{x:e.lx,y:e.ly,textAnchor:e.anchor,className:`lr-sub lr-good`,children:e.label})]},e.loop)),i.mode===`flow`&&i.inner.map(e=>(0,F.jsxs)(`g`,{children:[(0,F.jsx)(`rect`,{x:e.box.x,y:e.box.y,width:e.box.w,height:e.box.h,rx:`14`,className:`lr-box`}),(0,F.jsx)(`text`,{x:e.box.x+10,y:e.box.y-6,className:`lr-sub lr-good`,children:e.label})]},e.loop)),i.arcs.map((e,t)=>(0,F.jsx)(`path`,{d:e.d,className:`lr-${e.kind}`,markerEnd:`url(#lr-arrow-${e.kind})`},t)),i.entry.length>0&&(0,F.jsxs)(`g`,{children:[(0,F.jsx)(`path`,{d:`M40,${i.entry.at(-1).y} L${D},${i.entry.at(-1).y}`,className:`lr-flow`,markerEnd:`url(#lr-arrow-flow)`}),i.entry.map(e=>(0,F.jsxs)(`g`,{children:[(0,F.jsx)(`text`,{x:e.x,y:e.y-10,className:`lr-lbl`,children:e.name}),(0,F.jsx)(`text`,{x:e.x,y:e.y+18,className:`lr-sub`,children:`setup · 1×`}),e.human?(0,F.jsx)(I,{x:e.x-14,y:e.y-14,label:e.human}):null]},e.name))]}),i.nodes.map(e=>e.gate?(0,F.jsxs)(`g`,{className:`lr-gate`,children:[(0,F.jsx)(`title`,{children:`validate — the engine scores the change before the first mutate step`}),(0,F.jsx)(`circle`,{cx:e.x,cy:e.y,r:e.r}),(0,F.jsx)(`text`,{x:e.x,y:e.y+5,textAnchor:`middle`,children:`⛨`}),(0,F.jsx)(`text`,{x:e.x+20,y:e.y-10,className:`lr-sub lr-warn`,children:`validate`})]},e.name):(0,F.jsxs)(`g`,{className:`lr-node${e.inner?` inner`:``}${e.effect===`mutate`?` mutate`:``}${e.name===r?` current`:``}`,"aria-current":e.name===r?`step`:void 0,role:`button`,tabIndex:0,"aria-label":`${e.name} brick${e.human?`, ${e.human.toLowerCase()}`:``}`,onClick:o(e.name),onKeyDown:o(e.name),children:[(0,F.jsx)(`circle`,{cx:e.x,cy:e.y,r:e.r}),(0,F.jsx)(`text`,{x:e.x,y:e.y+4,textAnchor:`middle`,children:e.name}),e.human?(0,F.jsx)(I,{x:e.x+e.r*.74,y:e.y-e.r*.74,label:e.human}):null]},e.name)),i.exit&&(0,F.jsxs)(`g`,{children:[(0,F.jsx)(`path`,{d:i.exit.d,className:`lr-flow`,markerEnd:`url(#lr-arrow-flow)`}),(0,F.jsx)(`text`,{x:i.exit.x+6,y:i.exit.y+4,className:`lr-lbl`,children:`close`}),(0,F.jsx)(`text`,{x:i.exit.x-90,y:i.exit.y-10,textAnchor:`middle`,className:`lr-sub`,children:`done`})]}),i.center&&a&&(0,F.jsxs)(`g`,{children:[(0,F.jsx)(`text`,{x:i.center.x,y:i.center.y-4,textAnchor:`middle`,className:`lr-title`,children:e.name}),(0,F.jsxs)(`text`,{x:i.center.x,y:i.center.y+16,textAnchor:`middle`,className:`lr-sub lr-acc`,children:[`iterations · max `,a.max]})]})]})}var R=5e3,z=[`prudent`,`balanced`,`aggressive`],B={running:`acc`,awaiting:`warn`,unreadable:`bad`},V=e=>!!e.graph;function H(){let[e,t]=(0,g.useState)(null),[n,i]=(0,g.useState)(null),[a,o]=(0,g.useState)(0);return l(e=>r.activeLoops().then(n=>e()&&(t(n),i(null)),t=>e()&&i(t.message)),R,[a]),{loops:e?.loops??null,error:n,onPreset:(e,t)=>r.setLoopPreset(e,t).then(()=>o(e=>e+1),e=>i(e.message))}}function ee({history:e}){return e.length?(0,F.jsx)(`div`,{className:`loop-history`,children:(0,F.jsxs)(`table`,{className:`tbl`,children:[(0,F.jsx)(`thead`,{children:(0,F.jsx)(`tr`,{children:[`iteration`,`intent`,`declared`,`actual`,`decision`,`tests`].map(e=>(0,F.jsx)(`th`,{children:e},e))})}),(0,F.jsx)(`tbody`,{children:e.map(e=>(0,F.jsxs)(`tr`,{children:[(0,F.jsx)(`td`,{className:`num`,children:e.iteration}),(0,F.jsx)(`td`,{children:e.intent}),(0,F.jsx)(`td`,{className:`num`,children:e.declared}),(0,F.jsx)(`td`,{className:`num`,children:e.actual}),(0,F.jsx)(`td`,{children:e.decision}),(0,F.jsx)(`td`,{children:e.tests})]},e.iteration))})]})}):(0,F.jsx)(`p`,{className:`panel-note`,children:`No iteration finished yet.`})}function te({loop:e,bricks:t,onPreset:n}){let r=V(e)?(e.graph.loops||[]).find(e=>e.iteration):null;return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)(`div`,{className:`reader-tags`,children:[(0,F.jsx)(`span`,{className:`tag acc`,children:`Active loop`}),(0,F.jsx)(`span`,{className:`tag${B[e.status]?` ${B[e.status]}`:``}`,children:e.status})]}),(0,F.jsx)(`h2`,{className:`reader-title`,children:e.title}),(0,F.jsxs)(`p`,{className:`mono dim reader-src`,children:[e.branch,` · `,e.root]}),V(e)?(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)(`p`,{className:`reader-lede`,children:[`Iteration `,e.iteration,r?` / ${r.max}`:``,` · at `,e.node]}),e.awaiting?(0,F.jsxs)(`p`,{className:`loop-run-wait t-warn`,children:[(0,F.jsxs)(`b`,{children:[`Awaiting `,e.awaiting.kind,e.awaiting.kind===`gate`?` at ${e.awaiting.node}`:``]}),` `,`— Answer in the agent's session.`]}):null,(0,F.jsxs)(`label`,{className:`panel-note loop-run-preset`,children:[`preset`,(0,F.jsx)(`select`,{className:`sel`,"aria-label":`Preset for ${e.title}`,value:e.preset,onChange:t=>n(e.root,t.target.value),children:z.map(e=>(0,F.jsx)(`option`,{children:e},e))})]}),(0,F.jsx)(`hr`,{className:`hr`}),(0,F.jsx)(`div`,{className:`loop-graph`,children:(0,F.jsx)(L,{graph:e.graph,bricks:t,highlight:e.node})}),(0,F.jsx)(`h3`,{className:`loop-h2`,children:`Iterations`}),(0,F.jsx)(ee,{history:e.history})]}):(0,F.jsx)(`p`,{className:`reader-lede`,children:e.status===`unreadable`?`Its LOOP.md cannot be read, so there is no state to show.`:`Its LOOP.md is gone: the loop closed and its state went with it.`})]})}var U=encodeURIComponent,W=o.loops.map(e=>[e,s[e]]),G={architecture:`Architecture`,tests:`Tests`,development:`Development`,refactoring:`Refactoring`,"day-to-day":`Day-to-day`},ne={project:`Project`,global:`Global`,shipped:`Shipped`},re={templates:`Categories`,bricks:`Origins`,active:`Statuses`},ie=[[`awaiting`,`Awaiting`],[`running`,`Running`],[`done`,`Done · stopped`],[`stopped`,`Done · stopped`],[`finished`,`Finished · unreadable`],[`unreadable`,`Finished · unreadable`]];function K(e,t){let n=e.filter(e=>e.startsWith(`${t} (`)).at(-1);return n?/(overrides \w+)\)$/.exec(n)?.[1]:null}var q=(e,t,n)=>n.flatMap(([n,r])=>e.filter(e=>t(e)===n).map(e=>({...e,group:r})));function J(e,t){let n=new Set(t.filter(e=>e.gate===`human`).map(e=>e.name));return q(e.map(e=>({...e,desc:e.description,human:e.graph.nodes.some(e=>n.has(e))})),e=>G[e.graph.category]?e.graph.category:`other`,[...Object.entries(G),[`other`,`Other`]])}function Y(e,t){return q(e.map(e=>({...e,desc:e.description,override:K(t,e.name)})),e=>e.origin,Object.entries(ne))}function X(e){return q(e.map(e=>({...e,name:e.root,desc:e.branch})),e=>e.status,ie)}var Z=(e,t)=>(0,F.jsx)(`span`,{className:`tag${e?` ${e}`:``}`,children:t},t),Q={templates:e=>e.human?Z(`human`,`human gate`):null,bricks:e=>[e.effect===`mutate`?Z(`warn`,`mutate`):null,M(e)?Z(`human`,`human gate`):null,e.override?Z(`acc`,e.override):null,e.available===!1?Z(`bad`,`unavailable`):null],active:e=>Z(B[e.status],e.status)};function ae({name:e,brick:t,override:n,on:r}){let i=`loop-brick${r?` on`:``}${!t||t.available===!1?` dimmed`:``}`;return t?(0,F.jsxs)(`li`,{className:i,id:`brick-${e}`,children:[(0,F.jsx)(`b`,{children:(0,F.jsx)(`a`,{href:`#/loops/bricks/${U(e)}`,children:e})}),Z(t.effect===`mutate`?`warn`:``,t.effect),(0,F.jsx)(`span`,{className:`mono dim`,children:t.agent||t.skill}),(0,F.jsx)(`span`,{className:`panel-note`,children:t.outcomes.join(` · `)}),M(t)?Z(`human`,M(t).toLowerCase()):null,n?Z(`acc`,n):null]}):(0,F.jsxs)(`li`,{className:i,id:`brick-${e}`,children:[(0,F.jsx)(`b`,{children:e}),(0,F.jsx)(`span`,{className:`panel-note`,children:`Not in the catalogue: this template cannot run as is.`})]})}function oe({t:e,bricks:t,overridden:n}){let[r,i]=(0,g.useState)(null),a=new Map(t.map(e=>[e.name,e]));return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)(`div`,{className:`reader-tags`,children:[(0,F.jsx)(`span`,{className:`tag acc`,children:`Template`}),G[e.graph.category]?Z(``,G[e.graph.category]):null,e.human?Z(`human`,`human gate`):null]}),(0,F.jsx)(`h2`,{className:`reader-title`,children:e.name}),e.description?(0,F.jsx)(`p`,{className:`reader-lede`,children:e.description}):null,(0,F.jsxs)(`p`,{className:`mono dim reader-src`,children:[`loops/`,e.name,`.json · `,e.origin]}),(0,F.jsx)(`hr`,{className:`hr`}),(0,F.jsx)(`div`,{className:`loop-graph`,children:(0,F.jsx)(L,{graph:e.graph,bricks:t,onSelect:e=>{i(e),document.getElementById(`brick-${e}`)?.scrollIntoView?.({behavior:`smooth`,block:`nearest`})}})}),e.graph.rules?.length?(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`h3`,{className:`loop-h2`,children:`Rules`}),(0,F.jsx)(`ul`,{className:`loop-rules`,"aria-label":`Rules every brick follows`,children:e.graph.rules.map(e=>(0,F.jsx)(`li`,{children:e},e))})]}):null,(0,F.jsx)(`h3`,{className:`loop-h2`,children:`Bricks`}),(0,F.jsx)(`ul`,{className:`loop-brick-list`,"aria-label":`Bricks in ${e.name}`,children:e.graph.nodes.map(e=>(0,F.jsx)(ae,{name:e,brick:a.get(e),override:K(n,e),on:r===e},e))})]})}function $(e){return`---\n${[[`name`,e.name],[`description`,e.description],[`effect`,e.effect],[e.agent?`agent`:`skill`,e.agent||e.skill],[`gate`,e.gate],[`gateOn`,e.gateOn?.join(`, `)],[`outcomes`,e.outcomes.join(`, `)]].filter(([,e])=>e).map(([e,t])=>`${e}: ${t}`).join(`
|
|
2
|
-
`)}\n---\n${e.body}`}function se({b:e}){let[t,n]=(0,g.useState)(!1),r=[[`effect`,Z(e.effect===`mutate`?`warn`:``,e.effect)],[e.agent?`agent`:`skill`,(0,F.jsx)(`span`,{className:`mono`,children:e.agent||e.skill},`who`)],[`outcomes`,e.outcomes.map(e=>Z(``,e))],[`gate`,M(e)?Z(`human`,M(e).toLowerCase()):`none`],[`origin`,e.override?`${e.origin}, ${e.override}`:e.origin],[`available`,e.available===!1?(0,F.jsxs)(`span`,{className:`t-warn`,children:[`no — `,e.reason]},`why`):`yes`]];return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsxs)(`div`,{className:`reader-tags`,children:[(0,F.jsx)(`span`,{className:`tag acc`,children:`Brick`}),Q.bricks(e)]}),(0,F.jsx)(`h2`,{className:`reader-title`,children:e.name}),e.description?(0,F.jsx)(`p`,{className:`reader-lede`,children:e.description}):null,(0,F.jsxs)(`p`,{className:`mono dim reader-src`,children:[`bricks/`,e.name,`.md`]}),(0,F.jsx)(`dl`,{className:`loop-facts`,children:r.map(([e,t])=>(0,F.jsxs)(g.Fragment,{children:[(0,F.jsx)(`dt`,{children:e}),(0,F.jsx)(`dd`,{children:t})]},e))}),(0,F.jsx)(`hr`,{className:`hr`}),(0,F.jsx)(`div`,{className:`row gap-8 loop-src-bar`,children:(0,F.jsx)(`button`,{type:`button`,className:`btn ghost sm`,"aria-expanded":t,onClick:()=>n(!t),children:t?`Hide source`:`View source`})}),t?(0,F.jsx)(`pre`,{className:`loop-brick-src`,"aria-label":`Source`,children:$(e)}):(0,F.jsx)(`div`,{className:`lib-doc detail-doc`,children:(0,F.jsx)(h,{body:e.body})})]})}function ce({problems:e}){if(!e?.length)return null;let t=e.length;return(0,F.jsxs)(`div`,{className:`panel loop-problems`,role:`status`,"aria-label":`Catalogue files skipped`,children:[(0,F.jsxs)(`b`,{className:`t-warn`,children:[t,` catalogue `,t===1?`problem`:`problems`,`: these files were skipped`]}),(0,F.jsx)(`ul`,{className:`panel-note`,children:e.map(e=>(0,F.jsx)(`li`,{className:`mono`,children:e},e))})]})}var le={templates:(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`div`,{className:`big`,children:`No templates`}),`Add one under `,(0,F.jsx)(`code`,{className:`mono`,children:`.geneseed/loops/`}),` in the repo.`]}),bricks:(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`div`,{className:`big`,children:`No bricks`}),`Add one under `,(0,F.jsx)(`code`,{className:`mono`,children:`.geneseed/bricks/`}),` in the repo.`]}),active:(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(`div`,{className:`big`,children:`No loops yet`}),`Start one with `,(0,F.jsx)(`code`,{className:`mono`,children:`geneseed loop init`}),` in a worktree, or ask the agent to run a loop. It shows up here while it runs.`]})};function ue({tab:e=`templates`,item:t,dataRev:n}){let{data:o,error:s}=i(()=>r.loops(),[n],`loops`),l=H(),[h,_]=(0,g.useState)(``),[v,y]=(0,g.useState)(`all`),[b,x]=(0,g.useState)(e);e!==b&&(x(e),_(``),y(`all`));let S=o?.bricks||[],C=e===`active`?l.loops&&X(l.loops):o&&(e===`bricks`?Y(o.bricks,o.overridden):J(o.templates,o.bricks)),w=C||[],T=p(w),E=v===`all`?w:w.filter(e=>e.group===v),D=h.trim(),O=f(E,D),k=w.find(e=>e.name===t)||e===`active`&&w.find(V)||w[0]||null,A={templates:o?.templates.length,bricks:o?.bricks.length,active:l.loops?.length},j=(A.templates??0)+(A.bricks??0)+(A.active??0),M=e=>`${j?(e??0)/j*100:0}%`,N=W.find(([t])=>t===e)[1],P=e===`active`?l.error:s;return(0,F.jsxs)(F.Fragment,{children:[(0,F.jsx)(c,{error:P,style:{margin:`0 0 12px`}}),(0,F.jsx)(ce,{problems:o?.problems}),(0,F.jsxs)(`div`,{className:`library`,children:[(0,F.jsxs)(`aside`,{className:`lib-kinds`,"aria-label":`Loops sections`,children:[(0,F.jsxs)(`div`,{className:`lib-title`,children:[(0,F.jsx)(`h1`,{className:`h`,children:`Loops`}),(0,F.jsx)(`span`,{className:`dim`,children:`What the engine runs`})]}),(0,F.jsxs)(`div`,{className:`stackbar thin`,"aria-hidden":`true`,children:[(0,F.jsx)(`span`,{className:`sb-invariants`,style:{width:M(A.templates)}}),(0,F.jsx)(`span`,{className:`sb-doctrines`,style:{width:M(A.bricks)}}),(0,F.jsx)(`span`,{className:`sb-rest`,style:{width:M(A.active)}})]}),(0,F.jsx)(`nav`,{className:`kind-list`,"aria-label":`Sections`,children:W.map(([t,n])=>(0,F.jsxs)(g.Fragment,{children:[(0,F.jsxs)(`a`,{href:`#/loops/${t}`,className:e===t?`on`:``,"aria-current":e===t?`page`:void 0,children:[n,(0,F.jsx)(`span`,{className:`mono dim`,children:A[t]??``})]}),e===t&&(0,F.jsx)(u,{label:re[t],total:w.length,cats:T,cat:v,onChange:y})]},t))})]}),(0,F.jsx)(d,{label:N,count:D?`${O.length} of ${E.length}`:C?E.length:``,q:h,onQ:_,matched:O.length,inView:[e,t],children:C?w.length===0?(0,F.jsx)(`div`,{className:`empty`,style:{padding:32},children:le[e]}):(0,F.jsx)(m,{rows:O,activeName:k?.name,hrefOf:t=>`#/loops/${e}/${U(t.name)}`,pills:Q[e]}):P?null:(0,F.jsx)(a,{})}),(0,F.jsx)(`article`,{className:`lib-reader`,"aria-label":`Entry`,children:k?e===`active`?(0,F.jsx)(te,{loop:k,bricks:S,onPreset:l.onPreset}):e===`bricks`?(0,F.jsx)(se,{b:k}):(0,F.jsx)(oe,{t:k,bricks:S,overridden:o.overridden},k.name):null})]})]})}export{X as activeRows,Y as brickRows,$ as brickSource,ue as default,J as templateRows};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{n as e,r as t}from"./sections-BET3c1WT.js";import{i as n,t as r}from"./react-BOF6yL40.js";import{F as i,N as a}from"./index-DQXG_mqo.js";import{t as o}from"./jobBuckets-Dbq8ZlWW.js";n();var s=r(),c=14,l=120;function u({title:e,right:t,children:n,span:r}){return(0,s.jsxs)(`div`,{className:`c-mod`,style:r?{gridColumn:`span ${r}`}:null,children:[(0,s.jsxs)(`div`,{className:`c-mod-head`,children:[(0,s.jsx)(`span`,{className:`c-tab`}),(0,s.jsx)(`h3`,{children:e}),t&&(0,s.jsx)(`span`,{className:`c-mod-right`,children:t})]}),(0,s.jsx)(`div`,{className:`c-mod-body`,children:n})]})}function d({label:e,value:t}){return(0,s.jsxs)(`div`,{className:`c-kpi`,children:[(0,s.jsx)(`div`,{className:`c-kpi-label`,children:e}),(0,s.jsx)(`div`,{className:`c-kpi-val`+(t===0?` zero`:``),children:t})]})}function f({data:e,height:t=120,hi:n}){if(!e.length)return null;let r=Math.max(...e.map(e=>e.v),1);return(0,s.jsx)(`div`,{className:`c-cols`,style:{height:t},children:e.map((e,i)=>{let a=Math.max(e.v/r*(t-6),2);return(0,s.jsx)(`div`,{className:`c-col ${i===n?`hi`:``}`,style:{height:a},title:`${e.t}: ${e.v}`},i)})})}function p({checks:e}){return(0,s.jsx)(`div`,{className:`c-band`,children:e.map((e,t)=>(0,s.jsx)(`span`,{className:`c-band-cell ${e.problems.length===0?`ok`:`bad`}`,title:`${e.label}: ${e.problems.length===0?`pass`:`${e.problems.length} problem(s)`}`},t))})}function m(e){let t={};for(let n of e||[]){let e=n.action||`unknown`;t[e]=(t[e]||0)+1}return Object.entries(t).map(([e,t])=>({label:e,value:t})).sort((e,t)=>t.value-e.value)}function h({overview:n,jobs:r,doctor:h,onAction:g}){let _=n.counts||{},v=t.reduce((e,t)=>e+(_[t]||0),0),y=Math.max(...t.map(e=>_[e]||0),1),b=h?.groups||[],x=b.filter(e=>e.problems.length===0).length,S=o(r||[],10,`0d`),C=S.reduce((e,t)=>e+t.v,0),w=m(r),T=Math.max(...w.map(e=>e.value),1),E=i(n.diff),D=[[`status`,n.deployed?(0,s.jsx)(`span`,{className:`c-pill ok`,children:`DEPLOYED`}):(0,s.jsx)(`span`,{className:`c-pill warn`,children:`NOT DEPLOYED`})],[`voice`,(0,s.jsx)(`span`,{style:{textTransform:`capitalize`},children:n.theme})],[`mode`,n.emit],[`doctor`,b.length===0?(0,s.jsx)(`span`,{className:`c-pill`,children:`—`}):x===b.length?(0,s.jsx)(`span`,{className:`c-pill ok`,children:`CLEAN`}):(0,s.jsxs)(`span`,{className:`c-pill warn`,children:[b.length-x,` ISSUES`]})],[`edits`,String(E)],[`built`,n.build_time||`—`],[`target`,(0,s.jsx)(`span`,{className:`c-dim mono`,children:n.target})]];return(0,s.jsxs)(`div`,{className:`c-root`,children:[(0,s.jsxs)(`div`,{className:`c-titlebar`,children:[(0,s.jsxs)(`div`,{children:[(0,s.jsx)(`h1`,{className:`c-h1`,children:`HARNESS // STATUS READOUT`}),(0,s.jsxs)(`div`,{className:`c-sub`,children:[n.target,` · rendered from src/ · inherited everywhere`]})]}),(0,s.jsxs)(`div`,{className:`row gap-8`,children:[(0,s.jsxs)(`button`,{className:`btn`,onClick:()=>g(`update`),children:[(0,s.jsx)(a,{name:`refresh`}),`UPDATE`]}),(0,s.jsx)(`button`,{className:`btn ghost`,onClick:()=>g(`build-all`),children:`REBUILD`}),(0,s.jsx)(`button`,{className:`btn ghost`,onClick:()=>g(`doctor`),children:`DOCTOR`})]})]}),(0,s.jsx)(`div`,{className:`c-strip`,children:D.map(([e,t],n)=>(0,s.jsxs)(`div`,{className:`c-strip-cell`,children:[(0,s.jsx)(`div`,{className:`c-strip-k`,children:e}),(0,s.jsx)(`div`,{className:`c-strip-v`,children:t})]},n))}),(0,s.jsxs)(`div`,{className:`c-kpi-row`,children:[(0,s.jsx)(d,{label:`AGENTS`,value:_.agents??`—`}),(0,s.jsx)(d,{label:`SKILLS`,value:_.skills??`—`}),(0,s.jsx)(d,{label:`DICTATES`,value:_.laws??`—`}),(0,s.jsx)(d,{label:`PACKS`,value:_.doctrines?`${_.doctrines.active}/${_.doctrines.total}`:`—`}),(0,s.jsx)(d,{label:`MEMORY`,value:_.memory??`—`}),(0,s.jsx)(d,{label:`NOTEBOOK`,value:_.notebook??`—`}),(0,s.jsx)(d,{label:`EDITS`,value:E})]}),(0,s.jsxs)(`div`,{className:`c-grid`,children:[(0,s.jsx)(u,{title:`CAPABILITY DISTRIBUTION`,right:`${v} ENTRIES`,span:2,children:(0,s.jsxs)(`table`,{className:`c-tbl`,children:[(0,s.jsx)(`thead`,{children:(0,s.jsxs)(`tr`,{children:[(0,s.jsx)(`th`,{children:`SECTION`}),(0,s.jsx)(`th`,{children:`DETAIL`}),(0,s.jsx)(`th`,{style:{width:150},children:`SHARE`}),(0,s.jsx)(`th`,{className:`num`,children:`N`})]})}),(0,s.jsx)(`tbody`,{children:t.map(t=>(0,s.jsxs)(`tr`,{children:[(0,s.jsx)(`td`,{className:`c-name`,children:e[t].label}),(0,s.jsx)(`td`,{className:`c-dim`,children:e[t].desc}),(0,s.jsx)(`td`,{children:(0,s.jsx)(`div`,{className:`c-bar`,children:(0,s.jsx)(`i`,{style:{width:`${(_[t]||0)/y*100}%`,background:t===`agents`||t===`skills`?`var(--accent)`:`var(--line-3)`}})})}),(0,s.jsx)(`td`,{className:(_[t]||0)>0?`num`:`num c-dim`,children:_[t]??0})]},t))})]})}),(0,s.jsx)(u,{title:`DOCTOR // CHECKS`,right:b.length?`${x}/${b.length}`:`—`,children:b.length>0?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(p,{checks:b}),(0,s.jsx)(`div`,{className:`c-check-list`,children:b.map(e=>{let t=e.problems.length===0;return(0,s.jsxs)(`div`,{className:`c-check-row`,children:[(0,s.jsx)(`span`,{className:`c-dotmark ${t?`ok`:`bad`}`}),(0,s.jsx)(`span`,{className:`c-check-name`,children:e.label}),(0,s.jsx)(`span`,{className:`c-check-detail`,children:t?`clean`:`${e.problems.length} problem${e.problems.length===1?``:`s`}`})]},e.label)})})]}):(0,s.jsx)(`p`,{className:`c-dim mono`,style:{fontSize:11},children:`No doctor run loaded yet.`})}),(0,s.jsxs)(u,{title:`RUN RATE // 10D`,right:`${C} RUNS`,span:2,children:[(0,s.jsx)(f,{data:S,height:120,hi:S.length-1}),(0,s.jsx)(`div`,{className:`c-axis`,children:S.map((e,t)=>(0,s.jsx)(`span`,{children:t%2==0?e.t:``},t))})]}),(0,s.jsx)(u,{title:`RUN LOG // BY TYPE`,right:`${(r||[]).length} LOGGED`,children:w.length>0?(0,s.jsx)(`table`,{className:`c-tbl`,children:(0,s.jsx)(`tbody`,{children:w.map(e=>(0,s.jsxs)(`tr`,{children:[(0,s.jsx)(`td`,{className:`c-name`,style:{textTransform:`uppercase`,fontWeight:400},children:e.label}),(0,s.jsx)(`td`,{children:(0,s.jsx)(`div`,{className:`c-bar`,children:(0,s.jsx)(`i`,{style:{width:`${e.value/T*100}%`,background:`var(--accent)`}})})}),(0,s.jsx)(`td`,{className:`num`,children:e.value})]},e.label))})}):(0,s.jsx)(`p`,{className:`c-dim mono`,style:{fontSize:11},children:`No runs logged.`})}),(0,s.jsx)(u,{title:`RECENT // RUN LOG`,span:3,children:(0,s.jsx)(`table`,{className:`c-tbl`,children:(0,s.jsxs)(`tbody`,{children:[(r||[]).slice(0,c).map(e=>{let t=e.status===`done`,n=e.status===`failed`?`bad`:t?`ok`:`acc`,r=e.output?e.output.split(`
|
|
2
|
-
`)[0].slice(0,l):`—`;return(0,s.jsxs)(`tr`,{children:[(0,s.jsxs)(`td`,{style:{width:96},children:[(0,s.jsx)(`span`,{className:`c-dotmark ${n}`}),` `,(0,s.jsx)(`span`,{className:`c-dim`,children:e.action})]}),(0,s.jsx)(`td`,{className:`c-name`,style:{fontWeight:400},children:r}),(0,s.jsx)(`td`,{className:`num c-dim`,children:e.duration?`${e.duration}s`:e.status})]},e.id)}),(!r||r.length===0)&&(0,s.jsx)(`tr`,{children:(0,s.jsx)(`td`,{colSpan:`3`,className:`c-dim`,style:{fontSize:11},children:`No runs logged.`})})]})})})]})]})}export{h as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{B as i,C as a,S as o,T as s,x as c,y as l}from"./index-DQXG_mqo.js";import{t as u}from"./Markdown-iHvBrpRN.js";import{t as d}from"./Tabs-BOD7Kaz1.js";import f from"./Library-BWwiy9Vb.js";var p=e(t(),1),m=n(),h={title:``,body:``,scope:`project`,trial_until:``};function g({initial:e,onCancel:t,onSave:n,busy:r}){let[i,a]=(0,p.useState)(e),o=e=>t=>a({...i,[e]:t.target.value}),s=i.title.trim()&&i.body.trim();return(0,m.jsxs)(`div`,{className:`rule-form`,children:[(0,m.jsx)(`input`,{className:`lib-filter`,type:`text`,value:i.title,onChange:o(`title`),placeholder:`Title — short and imperative (e.g. No emoji in commit subjects)`,"aria-label":`Rule title`}),(0,m.jsx)(`textarea`,{className:`rule-body-input`,value:i.body,onChange:o(`body`),rows:4,placeholder:`The rule, stated plainly and testably, in one short paragraph.`,"aria-label":`Rule body`}),(0,m.jsxs)(`div`,{className:`row`,style:{flexWrap:`wrap`},children:[(0,m.jsxs)(`select`,{className:`sel`,value:i.scope,onChange:o(`scope`),"aria-label":`Rule scope`,children:[(0,m.jsx)(`option`,{value:`project`,children:`scope: project (this repo, committable)`}),(0,m.jsx)(`option`,{value:`user`,children:`scope: user (personal)`})]}),(0,m.jsxs)(`label`,{className:`rule-trial-label`,children:[`trial until`,(0,m.jsx)(`input`,{className:`lib-filter rule-date`,type:`date`,value:i.trial_until,onChange:o(`trial_until`),"aria-label":`Trial until date (optional)`})]}),(0,m.jsxs)(`div`,{style:{marginLeft:`auto`,display:`flex`,gap:8},children:[(0,m.jsx)(`button`,{className:`btn sm`,disabled:!s||r,onClick:()=>n(i),children:r?`Saving…`:`Save rule`}),(0,m.jsx)(`button`,{className:`btn ghost sm`,disabled:r,onClick:t,children:`Cancel`})]})]})]})}function _({rule:e,isOpen:t,onToggle:n,onEdit:r,onDelete:i,onGraduate:a}){return(0,m.jsxs)(`div`,{className:`rule-row ${t?`on`:``}`,children:[(0,m.jsxs)(`button`,{className:`rule-head`,onClick:n,"aria-expanded":t,children:[(0,m.jsxs)(`span`,{className:`rule-no`,children:[`R`,e.id]}),(0,m.jsx)(`span`,{className:`rule-title`,children:e.title}),(0,m.jsx)(`span`,{className:`rule-chip ${e.scope===`user`?`user`:``}`,children:e.scope}),e.status===`trial`&&(0,m.jsx)(`span`,{className:`rule-chip trial ${e.overdue?`overdue`:``}`,children:e.overdue?`review due`:`trial · ${e.trial_until}`})]}),t&&(0,m.jsxs)(`div`,{className:`rule-expand`,children:[(0,m.jsx)(`p`,{children:e.body}),e.source?(0,m.jsxs)(`div`,{className:`rule-src`,children:[`source: `,e.source]}):null,(0,m.jsxs)(`div`,{className:`row`,style:{marginTop:10,gap:8},children:[e.status===`trial`&&(0,m.jsx)(`button`,{className:`btn sm`,onClick:a,title:`Adopt for good — drop the trial marker`,children:`Graduate`}),(0,m.jsx)(`button`,{className:`btn ghost sm`,onClick:r,children:`Edit`}),(0,m.jsx)(`button`,{className:`btn ghost sm`,onClick:i,children:`Retire`})]})]})]})}function v({onChanged:e}){let t=o(),[n,s]=(0,p.useState)(0),{data:l,error:u}=i(()=>r.rules(),[n]),[d,f]=(0,p.useState)(null),[v,y]=(0,p.useState)(null),[b,x]=(0,p.useState)(!1),[S,C]=(0,p.useState)(``),w=()=>s(e=>e+1);if(u)return(0,m.jsx)(c,{error:u});if(!l)return(0,m.jsx)(a,{});let T=l.rules||[],{stats:E}=l,D=Math.round(Math.max(E.rules/E.max_rules,E.tokens/E.max_tokens)*100),O=D>=100?`over`:D>=70?`warn`:``,k=async t=>{x(!0),C(``);try{await r.rulesMutate({...t,fingerprint:l.fingerprint}),y(null)}catch(e){C(e.status===409?`user-rules.md changed on disk (an agent session?) — reloaded the fresh copy; re-apply your edit.`:e.message)}finally{x(!1),w(),e?.()}},A=async e=>{await t(`Retire rule R${e.id} — “${e.title}”? It is removed from user-rules.md.`,{title:`Retire this rule?`,confirmLabel:`Retire`})&&k({op:`delete`,id:e.id})},j=e=>k({op:`update`,id:e.id,title:e.title,body:e.body,scope:e.scope,source:e.source,trial_until:``});return(0,m.jsxs)(m.Fragment,{children:[(0,m.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,m.jsxs)(`div`,{children:[(0,m.jsx)(`div`,{className:`eyebrow`,children:`governance · yours`}),(0,m.jsx)(`h2`,{className:`h`,children:`Rules`}),(0,m.jsxs)(`p`,{className:`sub`,children:[`Your own standing rules, from `,(0,m.jsx)(`code`,{className:`mono`,children:`user-rules.md`}),` beside the deployed AGENT.md. The agent obeys them with the same force as the Laws — they may tighten a Law, never repeal one — and no update ever touches the file. Keep the set small: every rule is loaded every session.`]})]}),l.exists&&v===null&&(0,m.jsx)(`button`,{className:`btn`,onClick:()=>y(`new`),children:`Add rule`})]}),l.exists&&(0,m.jsxs)(`div`,{className:`rules-meter ${O}`,children:[(0,m.jsx)(`div`,{className:`rules-meter-bar`,children:(0,m.jsx)(`div`,{className:`rules-meter-fill`,style:{width:`${Math.min(D,100)}%`}})}),(0,m.jsxs)(`span`,{className:`rules-meter-label`,children:[E.rules,`/`,E.max_rules,` rules · ~`,E.tokens,` tokens`,D>=100?` — over budget: a bloated rule set dilutes the rules that matter`:D>=70?` — getting heavy; consider merging or pruning`:``]})]}),S?(0,m.jsx)(`p`,{className:`sub rule-notice`,children:S}):null,(l.warnings||[]).map(e=>(0,m.jsxs)(`p`,{className:`sub rule-notice`,children:[`format warning: `,e]},e)),v===`new`&&(0,m.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,m.jsx)(`div`,{className:`eyebrow`,style:{marginBottom:10},children:`new rule`}),(0,m.jsx)(g,{initial:h,busy:b,onCancel:()=>y(null),onSave:e=>k({op:`add`,...e})})]}),l.exists?T.length===0&&v!==`new`?(0,m.jsxs)(`div`,{className:`empty`,style:{padding:48},children:[(0,m.jsx)(`div`,{className:`big`,children:`No rules yet`}),`The file is seeded and loaded every session — it is just empty. Add your first standing rule here, ask the agent for one in-session (the rule skill), or promote a recurring memory fact from the Library.`]}):(0,m.jsx)(`div`,{className:`card rules-list`,children:T.map(e=>v===e.id?(0,m.jsx)(`div`,{className:`rule-row on`,children:(0,m.jsx)(`div`,{className:`rule-expand`,style:{paddingTop:14},children:(0,m.jsx)(g,{initial:{title:e.title,body:e.body,scope:e.scope,trial_until:e.trial_until},busy:b,onCancel:()=>y(null),onSave:t=>k({op:`update`,id:e.id,source:e.source,...t})})})},e.id):(0,m.jsx)(_,{rule:e,isOpen:d===e.id,onToggle:()=>f(d===e.id?null:e.id),onEdit:()=>{f(e.id),y(e.id)},onDelete:()=>A(e),onGraduate:()=>j(e)},e.id))}):(0,m.jsxs)(`div`,{className:`empty`,style:{padding:48},children:[(0,m.jsx)(`div`,{className:`big`,children:`No user-rules.md here yet`}),`The build seeds it beside AGENT.md — run a build/update from the Dashboard (or`,` `,(0,m.jsx)(`code`,{className:`mono`,children:`geneseed update`}),`) and it appears, ready for your rules.`]})]})}function y({onChanged:e}){let{data:t,error:n,loading:o,reload:l}=i(()=>r.profile(),[]),[d,f]=(0,p.useState)(``),[h,g]=(0,p.useState)(``),[_,v]=(0,p.useState)(!1),[y,b]=(0,p.useState)(``),[x,S]=(0,p.useState)(null),[C,w]=(0,p.useState)(!1),[T,E]=(0,p.useState)(null);t&&t!==T&&(E(t),g(t.fingerprint||``),C?w(!1):f(t.text||``),S(e=>e||((t.text||``).trim()?`view`:`edit`)));let D=!!t&&d!==(t.text||``);return(0,p.useEffect)(()=>{if(!D)return;let e=e=>{e.preventDefault(),e.returnValue=``};return window.addEventListener(`beforeunload`,e),()=>window.removeEventListener(`beforeunload`,e)},[D]),o&&!t?(0,m.jsx)(a,{}):n?(0,m.jsx)(c,{error:n}):(0,m.jsxs)(m.Fragment,{children:[(0,m.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,m.jsxs)(`div`,{children:[(0,m.jsx)(`div`,{className:`eyebrow`,children:`identity · yours`}),(0,m.jsx)(`h2`,{className:`h`,children:`Profile`}),(0,m.jsxs)(`p`,{className:`sub`,children:[`Who you are and how you like to work, from `,(0,m.jsx)(`code`,{className:`mono`,children:`PROFILE.md`}),` `,`beside the deployed AGENT.md. Unlike `,(0,m.jsx)(`code`,{className:`mono`,children:`user-rules.md`}),`, it is identity, not rules — it colours how the agent works but never binds (precedence is Laws, then rules, then this). Seeded once, never overwritten by an update. Prefer not to write it by hand? Ask the agent to run the `,(0,m.jsx)(`code`,{className:`mono`,children:`profile`}),` skill — it interviews you and drafts this file with your consent.`]})]}),(0,m.jsxs)(`div`,{className:`row`,style:{display:`flex`,alignItems:`center`,gap:12},children:[(0,m.jsx)(s,{"aria-label":`Profile mode`,children:[[`view`,`View`],[`edit`,`Edit`]].map(([e,t])=>(0,m.jsx)(`button`,{className:x===e?`on`:``,onClick:()=>S(e),children:t},e))}),x===`edit`&&(0,m.jsx)(`button`,{className:`btn`,disabled:!D||_,onClick:async()=>{v(!0),b(``);try{let t=await r.profileSave({text:d,fingerprint:h});t.ok?(g(t.fingerprint||``),b(`Saved.`),S(`view`),l(),e?.()):(w(!0),b(`${t.detail||`PROFILE.md changed on disk since you opened it.`} Your edit is kept — Save again to replace the newer version with it.`),l())}catch(e){b(e.message)}finally{v(!1)}},children:_?`Saving…`:`Save`})]})]}),y?(0,m.jsx)(`p`,{className:`sub rule-notice`,children:y}):null,x===`edit`?(0,m.jsx)(`textarea`,{className:`rule-body-input`,style:{width:`100%`,minHeight:`60vh`,fontFamily:`var(--mono, monospace)`},value:d,onChange:e=>f(e.target.value),spellCheck:!1,"aria-label":`Profile markdown`}):d.trim()?(0,m.jsx)(`div`,{className:`card pad-lg`,children:(0,m.jsx)(u,{body:d})}):(0,m.jsx)(`div`,{className:`card pad-lg`,children:(0,m.jsxs)(`p`,{className:`sub`,style:{margin:0},children:[`No profile yet — switch to Edit to write one, or ask the agent to run the`,` `,(0,m.jsx)(`code`,{className:`mono`,children:`profile`}),` skill.`]})})]})}var b=(e,t)=>`${t?Math.min(100,e/t*100):0}%`;function x({rules:e,profile:t,facts:n,notes:r}){let i=e?.exists?e.stats:null;if(!i)return null;let a=[{k:`Profile`,v:t?.seeded?`template`:t?.exists?`written`:`missing`,fill:t?.exists&&!t.seeded?1:0,warn:!!t?.seeded},{k:`Rules`,v:`${i.rules}/${i.max_rules}`,fill:i.rules/i.max_rules},{k:`Memory`,v:n==null?`n/a`:`${n} facts`,fill:+!!n},{k:`Notebook`,v:r==null?`n/a`:`${r} notes`,fill:+!!r}];return(0,m.jsxs)(`div`,{className:`card-row`,children:[(0,m.jsxs)(`section`,{className:`panel`,"aria-labelledby":`pc-budget`,children:[(0,m.jsxs)(`div`,{className:`panel-head`,children:[(0,m.jsx)(`h2`,{id:`pc-budget`,children:`Token budget`}),(0,m.jsx)(`span`,{className:`mono dim`,children:`loaded every turn`})]}),(0,m.jsxs)(`p`,{className:`big-num`,children:[(0,m.jsx)(`span`,{className:`mono`,children:i.tokens}),` `,(0,m.jsxs)(`span`,{className:`dim`,children:[`/ `,i.max_tokens.toLocaleString(`en-US`),` tokens`]})]}),(0,m.jsx)(`span`,{className:`hbar${i.tokens>i.max_tokens?` bad`:``}`,"aria-hidden":`true`,children:(0,m.jsx)(`span`,{style:{width:b(i.tokens,i.max_tokens)}})}),(0,m.jsx)(`p`,{className:`panel-note`,children:i.rules?`${i.rules} rules in ${i.lines} lines.`:`All of it is the file’s preamble; no rule text yet.`})]}),(0,m.jsxs)(`section`,{className:`panel`,"aria-labelledby":`pc-slots`,children:[(0,m.jsxs)(`div`,{className:`panel-head`,children:[(0,m.jsx)(`h2`,{id:`pc-slots`,children:`Rule slots`}),(0,m.jsxs)(`span`,{className:`mono dim`,children:[i.rules,` of `,i.max_rules]})]}),(0,m.jsx)(`div`,{className:`slots`,style:{"--slots":i.max_rules},role:`img`,"aria-label":`${i.rules} of ${i.max_rules} rule slots used`,children:Array.from({length:i.max_rules},(e,t)=>(0,m.jsx)(`span`,{className:t<i.rules?`used`:``},t))}),(0,m.jsx)(`p`,{className:`panel-note`,children:`Trial rules graduate once they have held.`})]}),(0,m.jsxs)(`section`,{className:`panel`,"aria-labelledby":`pc-known`,children:[(0,m.jsx)(`div`,{className:`panel-head`,children:(0,m.jsx)(`h2`,{id:`pc-known`,children:`What the agent knows about you`})}),(0,m.jsx)(`ul`,{className:`hbars`,children:a.map(e=>(0,m.jsxs)(`li`,{children:[(0,m.jsx)(`span`,{className:`hb-label`,children:e.k}),(0,m.jsx)(`span`,{className:`hb-track`,"aria-hidden":`true`,children:(0,m.jsx)(`span`,{className:`hb-ok`,style:{width:b(e.fill,1)}})}),(0,m.jsx)(`span`,{className:`mono hb-n${e.warn?` warn`:``}`,children:e.v})]},e.k))})]})]})}function S({tab:e=`rules`,item:t,setup:n,dataRev:a}){let o=e=>Promise.resolve(e).catch(()=>null),{data:s,reload:c}=l(a),{data:u,reload:p}=i(()=>o(r.profile()),[a]),{data:h}=i(()=>o(r.catalog(`notebook`)),[a],`catalog`),g=h?(h.items||[]).filter(e=>e.name!==`NOTEBOOK`&&e.name!==`README`).length:null,_=n?.facts??null,b={rules:s?.stats?.rules,profile:u?.seeded?`●`:null,memory:_,notebook:g};return(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(`div`,{className:`page-head`,children:(0,m.jsxs)(`div`,{children:[(0,m.jsx)(`h1`,{className:`h`,children:`Personal`}),(0,m.jsx)(`p`,{className:`sub`,children:`The only files you write. They survive updates, reinstalls and voice changes.`})]})}),(0,m.jsx)(d,{page:`personal`,current:e,badges:b,label:`Personal files`}),e===`rules`&&(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(x,{rules:s,profile:u,facts:_,notes:g}),(0,m.jsx)(v,{onChanged:c})]}),e===`profile`&&(0,m.jsx)(y,{onChanged:p}),(e===`memory`||e===`notebook`)&&(0,m.jsx)(f,{lock:e,base:`#/personal/${e}`,selected:t,dataRev:a,onRulesChanged:c},e)]})}export{S as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import"./sections-BET3c1WT.js";import{i as e,t}from"./react-BOF6yL40.js";import{G as n,K as r}from"./index-DQXG_mqo.js";e();var i=t();function a({page:e,current:t,badges:a={},label:o}){return(0,i.jsx)(`nav`,{className:`tabs`,"aria-label":o,children:n[e].map(n=>(0,i.jsxs)(`a`,{href:`#/${e}/${n}`,className:t===n?`on`:``,"aria-current":t===n?`page`:void 0,children:[r[n],a[n]==null?null:(0,i.jsx)(`span`,{className:`tab-badge`,children:a[n]})]},n))})}export{a as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";var r=e(t(),1),i=n(),a={busy:{cls:`acc`,label:`working`,accent:`var(--accent)`},"waiting-input":{cls:`warn`,label:`your move`,accent:`var(--warn)`},blocked:{cls:`bad`,label:`blocked`,accent:`var(--bad)`},idle:{cls:``,label:`idle`,accent:`var(--line)`}},o={overflow:`hidden`,textOverflow:`ellipsis`,whiteSpace:`nowrap`};function s(e){if(!e)return``;let t=e.replace(/\\/g,`/`).replace(/\/+$/,``).split(`/`);return t[t.length-1]||e}var c=e=>e?e<1e3?String(e):e<1e5?(e/1e3).toFixed(1)+`k`:e<1e6?(e/1e3).toFixed(0)+`k`:(e/1e6).toFixed(1)+`M`:`0`;function l(e){if(e=Math.max(0,Math.floor(e)),e<60)return`${e}s`;let t=Math.floor(e/60);return t<60?`${t}m ${e%60}s`:`${Math.floor(t/60)}h ${t%60}m`}function u({startedAt:e}){let[t,n]=(0,r.useState)(()=>Date.now()/1e3);return(0,r.useEffect)(()=>{let e=setInterval(()=>n(Date.now()/1e3),1e3);return()=>clearInterval(e)},[]),l(t-e)}function d({done:e,total:t}){let n=Math.min(t,10),r=Math.min(n,Math.round(e/t*n));return(0,i.jsxs)(`span`,{style:{letterSpacing:2},children:[(0,i.jsx)(`span`,{style:{color:`var(--accent)`},children:`●`.repeat(r)}),(0,i.jsx)(`span`,{style:{color:`var(--text-3)`},children:`○`.repeat(n-r)})]})}export{s as a,d as i,u as n,c as o,a as r,o as t};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var e=typeof window<`u`?window.__GENESEED_TOKEN__:``;async function t(e){let t=await e.json().catch(()=>({})),n=e.status===403&&t.error===`forbidden`?`the web server restarted since this page loaded — reload the page, then re-apply your edit`:t.error||t.message||e.statusText,r=Error(n);return r.status=e.status,r.body=t,r}async function n(e){let n=await fetch(e);if(!n.ok)throw await t(n);return n.json()}async function r(n,r={}){let i=await fetch(n,{method:`POST`,headers:{"X-Geneseed-Token":e||``,"Content-Type":`application/json`},body:JSON.stringify(r)});if(!i.ok)throw await t(i);return i.json()}var i=()=>n(`/api/overview`),a=()=>n(`/api/fleet`),o=()=>n(`/api/usage`),s=()=>n(`/api/gates`),c=()=>n(`/api/update`),l=()=>n(`/api/recent`),u=()=>n(`/api/activity`),d=e=>n(`/api/activity/`+encodeURIComponent(e)),f=e=>r(`/api/activity`,{enabled:e}),p=()=>n(`/api/setup`),m=(e=!1)=>n(e?`/api/doctor?fresh=1`:`/api/doctor`),h=()=>n(`/api/themes`),g=e=>n(`/api/catalog/${e}`),_=(e,t)=>n(`/api/item/${e}/${encodeURIComponent(t)}`),v=e=>r(`/api/memory/delete`,{name:e}),y=()=>n(`/api/diff`),b=e=>r(`/api/actions/restore`,{files:e}),x=409,S=e=>n(`/api/jobs/${e}`),C=()=>n(`/api/jobs`),w=e=>r(`/api/jobs/${e}/cancel`);async function T(e,t){try{return await r(`/api/actions/${e}`,t||{})}catch(e){throw e.status===x?Error(`An action is already running.`,{cause:e}):e}}var E=()=>n(`/api/loops`),D=()=>n(`/api/loops/active`),O=(e,t)=>r(`/api/loops/preset`,{root:e,preset:t}),k=()=>n(`/api/mcp`),A=e=>r(`/api/reveal`,{path:e}),j=()=>n(`/api/installs`),M=(e,t,n)=>r(`/api/install`,{host:e,path:t,action:n}),N=(e,t,n)=>r(`/api/install`,{host:e,path:t,action:`remove`,memory:n}),P=(e,t)=>r(`/api/view`,{host:e,path:t}),F=()=>r(`/api/pick-folder`,{}),I=()=>n(`/api/ping`),L=()=>r(`/api/shutdown`),R=()=>r(`/api/restart`),z=e=>e?`?harness=${encodeURIComponent(e)}`:``,B={fleet:a,usage:o,gates:s,update:c,loops:E,activeLoops:D,setLoopPreset:O,overview:i,recent:l,activity:u,activityDetail:d,activityToggle:f,setup:p,doctor:m,themes:h,catalog:g,item:_,memoryDelete:v,diff:y,restore:b,job:S,jobs:C,cancelJob:w,action:T,mcp:k,mcpReveal:A,installs:j,installToggle:M,installRemove:N,selectView:P,pickFolder:F,ping:I,shutdown:L,restart:R,docs:e=>n(`/api/docs${z(e)}`),docsPage:(e,t)=>n(`/api/docs/page/${encodeURIComponent(e)}${z(t)}`),rules:()=>n(`/api/rules`),rulesMutate:e=>r(`/api/rules`,e),rulesPromote:e=>r(`/api/rules/promote`,e),profile:()=>n(`/api/profile`),profileSave:e=>r(`/api/profile`,e),excludes:()=>n(`/api/excludes`),excludeMutate:(e,t)=>r(`/api/excludes`,{action:e,path:t})};export{B as t};
|