@north-light/cli 0.3.748 → 0.3.750
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/clients/attach/chrome/canvas-panels.d.ts +2 -0
- package/dist/clients/attach/chrome/canvas-panels.js +1 -1
- package/dist/clients/attach/chrome/roster.d.ts +2 -0
- package/dist/clients/attach/chrome/roster.js +5 -5
- package/dist/clients/attach/chrome/run-facts.d.ts +12 -0
- package/dist/clients/attach/chrome/run-facts.js +1 -0
- package/dist/clients/attach/chrome/widgets.d.ts +3 -1
- package/dist/clients/attach/chrome/widgets.js +1 -1
- package/dist/clients/attach/viewer.js +487 -487
- package/dist/core/canvas/canvas.js +16 -16
- package/dist/core/canvas/schema-pg/036-ledger-holder-app-path.sql +13 -0
- package/dist/core/canvas/schema-version.d.ts +1 -1
- package/dist/core/canvas/schema-version.js +1 -1
- package/dist/core/command.d.ts +1 -1
- package/dist/core/command.js +6 -6
- package/dist/core/grants/owner.d.ts +7 -0
- package/dist/core/grants/owner.js +1 -0
- package/dist/core/graph/reader.js +3 -3
- package/dist/core/import/load/bind.d.ts +1 -1
- package/dist/core/import/load/bind.js +11 -8
- package/dist/core/peer/envelope.js +1 -1
- package/dist/core/peer/stubs.js +1 -1
- package/dist/core/permissions/ceiling.js +10 -10
- package/dist/core/permissions/evaluator.js +2 -2
- package/dist/core/runtime/recap.js +6 -6
- package/dist/core/spaces/permissions.js +1 -1
- package/dist/core/spaces/process.js +1 -1
- package/dist/daemon/api/handlers/providers.d.ts +2 -0
- package/dist/daemon/api/handlers/providers.js +1 -1
- package/dist/daemon/peer/authority.d.ts +1 -1
- package/dist/daemon/peer/authority.js +1 -1
- package/package.json +4 -4
- package/packages/crouter-api/dist/clients/attach/chrome/canvas-panels.js +19 -1
- package/packages/crouter-api/dist/clients/attach/chrome/roster.js +1 -0
- package/packages/crouter-api/dist/clients/attach/chrome/run-facts.js +76 -0
- package/packages/crouter-api/dist/clients/attach/chrome/widgets.js +14 -5
- package/packages/crouter-api/dist/clients/attach/viewer.js +7 -1
- package/packages/crouter-api/dist/core/canvas/canvas.js +2 -1
- package/packages/crouter-api/dist/core/canvas/schema-version.js +1 -1
- package/packages/crouter-api/dist/core/command.js +4 -3
- package/packages/crouter-api/dist/core/grants/owner.js +15 -0
- package/packages/crouter-api/dist/core/graph/reader.js +9 -6
- package/packages/crouter-api/dist/core/peer/envelope.js +2 -1
- package/packages/crouter-api/dist/core/peer/stubs.js +5 -1
- package/packages/crouter-api/dist/core/permissions/ceiling.js +4 -0
- package/packages/crouter-api/dist/core/permissions/evaluator.js +13 -4
- package/packages/crouter-api/dist/core/spaces/permissions.js +10 -4
- package/packages/crouter-api/dist/core/spaces/process.js +5 -3
- package/packages/crouter-api/dist/daemon/api/handlers/providers.js +5 -1
- package/packages/crouter-api/package.json +1 -1
- package/packages/crouter-identity/dist/index.d.ts +8 -0
- package/packages/crouter-identity/dist/index.js +18 -0
- package/packages/crouter-identity/package.json +1 -1
- package/packages/crouter-plugin/package.json +3 -3
- package/runtime.lock.json +14 -14
- package/scripts/lib/install-source.mjs +5 -1
|
@@ -35,6 +35,8 @@ export interface CanvasPanelLines {
|
|
|
35
35
|
reportIds: string[];
|
|
36
36
|
/** Actionable cockpit rows. Enter swaps nodes or opens the matching wait detail surface. */
|
|
37
37
|
items: CanvasPanelItem[];
|
|
38
|
+
/** What `nodeId` itself waits on, for the fact line above the recap. */
|
|
39
|
+
waiting?: string;
|
|
38
40
|
}
|
|
39
41
|
/** What the nodes on the manager and report rows are waiting on. Omitted for a remote attach. */
|
|
40
42
|
export interface OtherNodeWaits {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var fn=Object.defineProperty;var s=(i,a)=>fn(i,"name",{value:a,configurable:!0});import{navLabel as I,nodeGlyph as hn,truncate as mn,tokensCell as wn,cycleBadge as gn,askBadge as pn,fillWidth as x,RESET as w,DIM as A,GREEN as $n}from"../../../core/canvas/nav-render.js";const _n=34,yn=30,bn=40;import{RemoteCanvasSource as vn}from"../../../core/canvas/remote-canvas-source.js";import{cronWaitSummary as U}from"./cron-wait.js";import{bashJobsWaitSummary as X}from"./bash-jobs.js";import{reviewWaitSummary as kn}from"./review-wait.js";import{objectWaitSummary as Y}from"./object-wait.js";import{formatBashElapsed as Mn}from"../../../core/bash-jobs.js";const Z=s((i,a)=>{const c=i==null?Number.NaN:Date.parse(i);return Number.isNaN(c)?void 0:Mn(a-c)},"since"),jn=12,On=6,nn=22;function tn(i,a){return i.length>a?`${i.slice(0,a-1)}\u2026`:i+" ".repeat(a-i.length)}s(tn,"nameCell");function Nn(i,a){return i.length>=a?i.slice(0,a):" ".repeat(a-i.length)+i}s(Nn,"padStartVisible");async function An(i,a,c,$,N=[],k=[],D=[],M,en){const H=$ instanceof vn,g=en,j=g===void 0?null:new Map(g.nodes.map(n=>[n.node_id,n])),W=new Map,C=new Map;if(g!==void 0)for(const n of g.edges){const t=W.get(n.from_id)??[];t.push(n.to_id),W.set(n.from_id,t),C.has(n.to_id)||C.set(n.to_id,n.from_id)}const P=new Map,T=new Map,F=new Map,_=s(n=>{const t=P.get(n);if(t!==void 0)return t;const e=j===null?$.getNode(n).catch(()=>null):Promise.resolve(j.get(n)??null);return P.set(n,e),e},"node"),G=s(n=>$.getNode(n).catch(()=>null),"detail"),E=s(n=>{const t=T.get(n);if(t!==void 0)return t;const e=(async()=>{const o=j===null?(await $.subscriptionsOf(n).catch(()=>[])).map(r=>r.node_id):W.get(n)??[],d=[];for(const r of o)(await _(r))?.kind!=="human"&&d.push(r);return d})();return T.set(n,e),e},"convoChildIds"),J=s(n=>{const t=F.get(n);if(t!==void 0)return t;const e=j===null?$.subscribersOf(n).then(o=>o[0]?.node_id).catch(()=>{}):Promise.resolve(C.get(n));return F.set(n,e),e},"managerOf"),K=s(async n=>{const t=[];for(const e of await E(n)){const o=(await _(e))?.status;(o==="active"||o==="idle")&&t.push(e)}return t},"liveReports"),on=s(async n=>{let t=n;const e=new Set([t]);for(;;){const o=await J(t);if(o===void 0||e.has(o))break;e.add(o),t=o}return t},"climbRoot"),L=new Map,sn=s(async n=>{const t=new Set,e=s(async o=>{const d=(await _(o))?.status==="active";if(t.has(o))return d?1:0;t.add(o);let r=0;for(const p of await E(o))r+=await e(p);return L.set(o,r),r+(d?1:0)},"visit");await e(n)},"computeActivity"),an=s(async n=>{if(n===null||n.mode!=="orchestrator")return"";const t=(await E(n.node_id)).length;return t>0?` ${A}\u2933${t}${w}`:""},"childBadgeFor"),cn=s(n=>{if(n===null||n.status==="active")return"";const t=L.get(n.node_id)??0;return t>0?` ${$n}\u21E3${t}${w}`:""},"liveBelowBadgeFor"),y=c?.muted??(n=>n),rn=c?.faint??(n=>n);await sn(await on(i));const f=await J(i),l=await K(i),O=[...f!==void 0?[f]:[],...l],V=await Promise.all(O.map(async n=>await G(n)??await _(n))),dn=O.length>0?Math.min(nn,Math.max(...O.map((n,t)=>I(V[t]??null,n).length))):nn,un=s(async(n,t)=>{if(H||t===null||t.status!=="active"&&t.status!=="idle")return"";const e=Date.now();if(t.streaming===!0){const b=[(t.telemetry_last_activity??"").trim(),Z(t.telemetry_updated_at,e)].filter(v=>v!==void 0&&v!=="");return b.length===0?"":` ${A}\xB7 ${b.join(" \xB7 ")}${w}`}const o=[],d=(await K(n)).length;if(d>0&&o.push(d===1?"1 child":`${d} children`),(a[n]??0)>0&&o.push("you"),M!==void 0){M.reviews.some(B=>B.origin_node_id===n)&&o.push("review");const u=await M.jobsOf(n).catch(()=>null),b=u===null?"bash jobs (could not read)":X(u,e,20);b!==void 0&&o.push(b.replace(/ · /g," "));const v=U(M.crons.filter(B=>B.created_by===n),e);v!==void 0&&o.push(v.replace(/ · /g," "))}for(const u of g?.object_waits??[])u.node_id===n&&o.push(Y(u,e,20).replace(/ · /g," "));const r=Z(t.last_settled_at,e),p=[r===void 0?void 0:`turn ended ${r} ago`,o.length===0?void 0:`waiting on ${o.join(", ")}`].filter(u=>u!==void 0);return p.length===0?"":` ${A}\xB7 ${p.join(" \xB7 ")}${w}`},"stateCell"),q=s(async(n,t)=>{const e=V[O.indexOf(n)]??null,o=tn(I(e,n),dn),d=rn(tn(e?.kind??"",jn)),r=y(Nn(wn(e,H),On)),p=`${gn(e)}${await an(e)}${cn(e)}${pn(n,a)}${await un(n,e)}`,u=` ${t} ${hn(e)} ${o} ${d} ${r}${p}`;return mn(u)},"row"),ln=[...f!==void 0?[f]:[],...l],h=[];f!==void 0&&h.push({key:`node:${f}`,kind:"node",nodeId:f,line:await q(f,"\u2191")});for(const n of l)h.push({key:`node:${n}`,kind:"node",nodeId:n,line:await q(n,"\u2193")});for(const n of D){const t=c?c.info("\u270E"):"\u270E",e=kn(n,Math.max(8,x()-bn));h.push({key:`review:${n.review_id}`,kind:"review",reviewId:n.review_id,line:` ${t} ${y(`${e} \xB7 \u21B5 open`)}${w}`})}const z=k.length===1?" \xB7 x stop":"",R=X(k,Date.now(),x()-(_n+z.length));if(R!==void 0){const n=c?c.info("\u2699"):"\u2699";h.push({key:"bash",kind:"bash",line:` ${n} ${y(`${R} \xB7 \u21B5 details${z}`)}${w}`})}const S=U(N);if(S!==void 0){const n=c?c.info("\u25F7"):"\u25F7";h.push({key:"crons",kind:"crons",line:` ${n} ${y(`${S} \xB7 \u21B5 details`)}${w}`})}for(const n of g?.object_waits??[]){if(n.node_id!==i)continue;const t=c?c.info("\u25C7"):"\u25C7",e=Y(n,Date.now(),Math.max(8,x()-yn));h.push({key:`object:${n.object_id}`,kind:"object-wait",objectId:n.object_id,line:` ${t} ${y(`${e} \xB7 \u21B5 details`)}${w}`})}const m=[];if((a[i]??0)>0&&m.push("you"),l.length>0){const n=I(await G(l[0])??await _(l[0]),l[0]);m.push(l.length===1?n:`${n} +${l.length-1}`)}D.length>0&&m.push("review"),R!==void 0&&m.push(k.length===1?"a bash job":`${k.length} bash jobs`),S!==void 0&&m.push(N.length===1?"a cron":`${N.length} crons`);for(const n of g?.object_waits??[])n.node_id===i&&m.push(n.object_name);const Q=m.length===0?void 0:m.join(", ");return{reports:h.map(n=>n.line),reportIds:ln,items:h,...Q===void 0?{}:{waiting:Q}}}s(An,"buildCanvasPanelLines");export{An as buildCanvasPanelLines};
|
|
@@ -25,6 +25,8 @@ export interface RosterHooks {
|
|
|
25
25
|
openObject: (objectId: string) => void;
|
|
26
26
|
/** Recompute the editor's hollow-cursor state (session/pane-focus.ts). */
|
|
27
27
|
syncCursor: () => void;
|
|
28
|
+
/** What this node waits on, from each rebuild — feeds the fact line above the recap. */
|
|
29
|
+
onWaiting?: (label: string | undefined) => void;
|
|
28
30
|
}
|
|
29
31
|
export interface AttachRoster {
|
|
30
32
|
/** Rebuild the rows from the canvas source, reconcile the selection, repaint. */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
var
|
|
2
|
-
`)[0]??"").replace(/\s+/g," ").trim();return c.length>i?`${c.slice(0,i-1)}\u2026`:c},"commandHead"),
|
|
3
|
-
`)[0]}`),n.requestChromeRefresh()}))},"confirmKill");
|
|
1
|
+
var P=Object.defineProperty;var o=(d,n)=>P(d,"name",{value:n,configurable:!0});import{execFile as x}from"node:child_process";import{Text as U,decodeKittyPrintable as V,matchesKey as h}from"@earendil-works/pi-tui";import{cliClient as y}from"../../../commands/api-client.js";import{daemonErrorMessage as R}from"../../inbox/resolve.js";import{openBrowser as W}from"../../open-browser.js";import{toBashJobStatus as K}from"./bash-jobs.js";import{fillBar as D,fillWidth as F,stripSgr as L,REVERSE as X}from"../../../core/canvas/nav-render.js";import{buildCanvasPanelLines as z}from"./canvas-panels.js";const G=15e3;function de(d,n){const{editor:B,tui:E,pal:k,remote:f,role:j,canvasSource:C}=d,N=d.containers.reports;let s=[],r,v=process.env.CRTR_ATTACH_ROSTER;v!==void 0&&delete process.env.CRTR_ATTACH_ROSTER;let a,g;const m=o(()=>{n.syncCursor(),N.clear();for(const e of s){const i=e.key===r;N.addChild(new U(i?D(L(e.line),F(),X):e.line,1,0))}E.requestRender()},"paint"),I=o(async()=>(await y().listBashJobs(d.nodeId)).map(K),"listJobs"),A=o(async e=>{const i=f?[]:await y().listCrons(),c=i.filter(l=>l.created_by===d.nodeId),t=f?[]:await I(),p=f?[]:(await y().listReviews({state:"open"})).reviews,w=p.filter(l=>l.origin_node_id===d.nodeId),H=f?void 0:{crons:i,reviews:p,jobsOf:o(async l=>(await y().listBashJobs(l)).map(K),"jobsOf")},S=await z(d.nodeId,n.asks(),k,C,c,t,w,H,e??await C.panelView?.(d.nodeId));if(s=S.items,n.onWaiting?.(S.waiting),v!==void 0){const l=v;v=void 0;const _=s.find($=>$.kind==="node"&&$.nodeId===l);_!==void 0&&(r=_.key)}r!==void 0&&!s.some(l=>l.key===r)&&(r=void 0),a!==void 0&&!t.some(l=>l.jobId===a?.jobId)&&b(!0),m()},"refresh"),b=o(e=>{g!==void 0&&(clearTimeout(g),g=void 0),a!==void 0&&(a=void 0,e&&n.setNotice(""))},"disarmKill"),u=o(()=>{b(!0),r!==void 0&&(r=void 0,m())},"exit"),T=o(e=>V(e)??(e.length===1?e:void 0),"typed"),q=o((e,i=40)=>{const c=(e.split(`
|
|
2
|
+
`)[0]??"").replace(/\s+/g," ").trim();return c.length>i?`${c.slice(0,i-1)}\u2026`:c},"commandHead"),J=o(async()=>{if(j!=="controller"){n.setNotice("Read-only observer attach \u2014 cannot stop background jobs");return}const e=await I();if(e.length===0){n.setNotice("Background job already finished"),n.requestChromeRefresh();return}if(e.length>1){n.setNotice(`${e.length} background jobs \u2014 press \u21B5 to pick one in the Inspector`);return}const i=e[0];a={jobId:i.jobId,label:q(i.command)},n.setNotice(`Stop \u201C${a.label}\u201D? Press y to confirm.`,{sticky:!0}),g=setTimeout(()=>b(!0),G)},"armKill"),M=o(()=>{const e=a;e!==void 0&&(b(!1),n.setNotice(`Stopping \u201C${e.label}\u201D\u2026`),x("crtr",["node","bash","kill",e.jobId,"--node",d.nodeId],i=>{n.setNotice(i===null?`Stopped \u201C${e.label}\u201D.`:`Could not stop the job: ${i.message.split(`
|
|
3
|
+
`)[0]}`),n.requestChromeRefresh()}))},"confirmKill");B.onCursorDownAtBottom=f?void 0:()=>{r!==void 0||s.length===0||(r=s[0].key,m())};const O=o(()=>{const e=s.find(t=>t.key===r);if(e===void 0||f)return;if(e.kind==="crons"){u(),n.openInspector("schedule");return}if(e.kind==="review"){u(),(async()=>{const t=(await y().listHumanInbox()).tickets.find(p=>p.kind==="review"&&p.request_id===e.reviewId);if(t?.kind!=="review"||t.url===void 0){n.setNotice("Reviews open on canvas.northlight.ai; this runtime has no canvas host");return}W(t.url)})().catch(t=>n.setNotice(`Could not open the review: ${R(t).split(`
|
|
4
4
|
`)[0]}`));return}if(e.kind==="bash"){I().then(t=>{if(t.length===0){n.setNotice("Background job already finished"),n.requestChromeRefresh();return}u(),n.openInspector("jobs")},t=>n.setNotice(`Could not list background jobs: ${R(t).split(`
|
|
5
|
-
`)[0]}`));return}if(e.kind==="object-wait"){u(),n.openObject(e.objectId);return}const i=e.nodeId;if(i===d.nodeId){u();return}if(j!=="controller"){n.setNotice("Read-only observer attach \u2014 cannot focus nodes");return}const c=process.env.TMUX_PANE;if(c===void 0||c===""){n.setNotice("cannot swap \u2014 no tmux pane");return}
|
|
6
|
-
`)[0]}`)),!0):c?(t<=0?u():(r=s[t-1].key,m()),!0):i?(t>=0&&t<s.length-1&&(r=s[t+1].key,m()),!0):
|
|
5
|
+
`)[0]}`));return}if(e.kind==="object-wait"){u(),n.openObject(e.objectId);return}const i=e.nodeId;if(i===d.nodeId){u();return}if(j!=="controller"){n.setNotice("Read-only observer attach \u2014 cannot focus nodes");return}const c=process.env.TMUX_PANE;if(c===void 0||c===""){n.setNotice("cannot swap \u2014 no tmux pane");return}x("tmux",["run-shell","-b",`crtr surface node focus ${i} --pane ${c} --in-place >/dev/null 2>&1`],()=>{})},"openSelected");return{refresh:A,handleKey:o(e=>{if(f)return!1;const i=h(e,"down"),c=h(e,"up");if(r===void 0)return!1;const t=s.findIndex(w=>w.key===r),p=s[t];if(a!==void 0){if(T(e)==="y")return M(),!0;b(!0)}return p?.kind==="bash"&&T(e)==="x"?(J().catch(w=>n.setNotice(`Could not list background jobs: ${R(w).split(`
|
|
6
|
+
`)[0]}`)),!0):c?(t<=0?u():(r=s[t-1].key,m()),!0):i?(t>=0&&t<s.length-1&&(r=s[t+1].key,m()),!0):h(e,"enter")?(O(),!0):h(e,"escape")?(u(),!0):(u(),!1)},"handleKey"),active:o(()=>r!==void 0,"active"),exit:u}}o(de,"createRoster");export{de as createRoster};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { BrokerToClient } from '../../../core/runtime/broker-protocol.js';
|
|
2
|
+
export interface RunFacts {
|
|
3
|
+
/** Fold one broker frame: message timestamps move the run window. */
|
|
4
|
+
observe(frame: BrokerToClient): void;
|
|
5
|
+
/** What the node waits on, from the latest roster refresh. */
|
|
6
|
+
setWaiting(label: string | undefined): void;
|
|
7
|
+
/** The fact line, or undefined when there is nothing to show. */
|
|
8
|
+
line(streaming: boolean, nowMs?: number): string | undefined;
|
|
9
|
+
}
|
|
10
|
+
/** `2:31 PM` today, `Nov 18, 2:31 PM` on another day. */
|
|
11
|
+
export declare function finishLabel(atMs: number, nowMs: number): string;
|
|
12
|
+
export declare function createRunFacts(onChange: () => void): RunFacts;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var a=Object.defineProperty;var o=(t,i)=>a(t,"name",{value:i,configurable:!0});import{formatBashElapsed as f}from"../../../core/bash-jobs.js";import{isTrueUserMessage as p}from"../../../shared/tool-groups.js";function c(t){return typeof t.timestamp=="number"&&Number.isFinite(t.timestamp)?t.timestamp:void 0}o(c,"stamp");function m(t,i){const n=new Date(t),s=n.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit"});return n.toDateString()===new Date(i).toDateString()?s:`${n.toLocaleDateString("en-US",{month:"short",day:"numeric"})}, ${s}`}o(m,"finishLabel");function y(t){let i,n,s;const d=o(e=>{const r=c(e);r!==void 0&&(p(e)?(i=r,n=void 0):e.role==="assistant"&&(n=r))},"take");return{observe(e){if(e.type==="welcome"){i=void 0,n=void 0;for(const r of e.snapshot.messages)d(r);t();return}if(e.type==="agent_start"||e.type==="agent_end"||e.type==="agent_settled"){t();return}(e.type==="message_end"||e.type==="message_start"&&e.message.role==="user")&&(d(e.message),t())},setWaiting(e){e!==s&&(s=e,t())},line(e,r=Date.now()){if(e)return;const u=[];return n!==void 0&&(i!==void 0&&n>=i&&u.push(`ran ${f(n-i)}`),u.push(`finished ${m(n,r)}`)),s!==void 0&&u.push(`waiting on ${s}`),u.length===0?void 0:u.join(" \xB7 ")}}}o(y,"createRunFacts");export{y as createRunFacts,m as finishLabel};
|
|
@@ -6,4 +6,6 @@ export interface ChromeWidgets {
|
|
|
6
6
|
/** Paint the pending steering messages above the editor. */
|
|
7
7
|
renderQueued: () => void;
|
|
8
8
|
}
|
|
9
|
-
export declare function createChromeWidgets(ctx: Pick<AttachSession, 'tui' | 'pal' | 'containers'>, state: () => SessionState
|
|
9
|
+
export declare function createChromeWidgets(ctx: Pick<AttachSession, 'tui' | 'pal' | 'containers'>, state: () => SessionState,
|
|
10
|
+
/** The gray fact line (run time, finish time, waiting on), painted above the recap. */
|
|
11
|
+
factLine?: () => string | undefined): ChromeWidgets;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
var
|
|
1
|
+
var b=Object.defineProperty;var c=(n,s)=>b(n,"name",{value:s,configurable:!0});import{Spacer as y,Text as a,truncateToWidth as E,wrapTextWithAnsi as w}from"@earendil-works/pi-tui";import{splitRecapLines as R}from"./recap.js";function j(n,s,h=()=>{}){const{tui:f,pal:o}=n,{aboveWidgets:d,belowWidgets:p,queued:u}=n.containers;return{renderExtensionWidgets:c(()=>{const e=s();d.clear(),p.clear();const r=Math.max(1,(process.stdout.columns??80)-2),i=h();if(i!==void 0){for(const t of w(o.faint(i),r))d.addChild(new a(t,1,0));e.display.widgets["crtr-recap"]!==void 0&&d.addChild(new y(1))}for(const[t,l]of Object.entries(e.display.widgets)){const g=t==="crtr-recap",q=g?R(l.lines).state:l.lines,x=l.placement==="belowEditor"?p:d;for(const m of q){const W=g?o.faint(m):m;for(const C of w(W,r))x.addChild(new a(C,1,0))}}f.requestRender()},"renderExtensionWidgets"),renderQueued:c(()=>{const e=s();if(u.clear(),e.queued.length>0){const r=Math.max(1,(process.stdout.columns??80)-4);u.addChild(new a(o.muted(`queued (${e.queued.length}):`),1,0));for(const i of e.queued){const t=i.text.replace(/\s+/g," ").trim();u.addChild(new a(o.faint(` \u22EF ${E(t,r,"\u2026")}`),1,0))}}f.requestRender()},"renderQueued")}}c(j,"createChromeWidgets");export{j as createChromeWidgets};
|