Surface environment readiness in GUI
This commit is contained in:
parent
a0d798c5f8
commit
664f2c2598
9 changed files with 271 additions and 23 deletions
|
|
@ -269,6 +269,11 @@ export function App() {
|
|||
const canAcceptVerification = text(roleResults?.verification?.status).toLowerCase() === "completed";
|
||||
const canAcceptReorient = text(reorientResult?.status).toLowerCase() === "completed";
|
||||
const canContinueImplementation = text(coordinator.action).toLowerCase() === "continueimplementation";
|
||||
const unityBridge = latestRuntimeAudit?.editorBridge;
|
||||
const installedEditors = latestRuntimeAudit?.installedEditors ?? [];
|
||||
const candidatePaths = latestRuntimeAudit?.candidatePaths ?? [];
|
||||
const searchRoots = latestRuntimeAudit?.searchRoots ?? [];
|
||||
const unityBridgeReady = latestRuntimeAudit?.status === "ready" && unityBridge?.exists === true;
|
||||
|
||||
return (
|
||||
<main className="shell">
|
||||
|
|
@ -393,6 +398,58 @@ export function App() {
|
|||
</section>
|
||||
)}
|
||||
|
||||
<section className="sectionBand">
|
||||
<SectionHeader title="Environment" icon={<Database size={18} />} />
|
||||
<div className="environmentGrid">
|
||||
<article className="environmentCard">
|
||||
<div className="cardTopline">
|
||||
<h3>Unity Editor</h3>
|
||||
<Pill tone={unityBridgeReady ? "ok" : statusClass(latestRuntimeAudit?.status)}>
|
||||
{unityBridgeReady ? "bridge ready" : text(latestRuntimeAudit?.status, "unknown")}
|
||||
</Pill>
|
||||
</div>
|
||||
<dl className="facts environmentFacts">
|
||||
<div><dt>Project</dt><dd>{text(latestRuntimeAudit?.projectVersion)}</dd></div>
|
||||
<div><dt>Editor</dt><dd>{text(latestRuntimeAudit?.editorPath, "missing")}</dd></div>
|
||||
<div><dt>Package</dt><dd>{unityBridge?.exists ? "present" : "missing"}</dd></div>
|
||||
<div><dt>Method</dt><dd>{text(unityBridge?.executeMethod)}</dd></div>
|
||||
</dl>
|
||||
{latestRuntimeAudit?.note && <p className="environmentNote">{latestRuntimeAudit.note}</p>}
|
||||
<PathList title="Installed" items={installedEditors.map((editor) => `${text(editor.version)} ${text(editor.editorPath)}`)} />
|
||||
<PathList title="Candidates" items={candidatePaths} />
|
||||
</article>
|
||||
|
||||
<article className="environmentCard">
|
||||
<div className="cardTopline">
|
||||
<h3>Rider</h3>
|
||||
<Pill tone="neutral">pending</Pill>
|
||||
</div>
|
||||
<dl className="facts environmentFacts">
|
||||
<div><dt>Workspace</dt><dd>{text(request.cwd ?? snapshot?.repoRoot)}</dd></div>
|
||||
<div><dt>Plugin</dt><dd>not wired</dd></div>
|
||||
<div><dt>Diagnostics</dt><dd>pending</dd></div>
|
||||
<div><dt>Diff view</dt><dd>pending</dd></div>
|
||||
</dl>
|
||||
<p className="environmentNote">Bridge pending.</p>
|
||||
</article>
|
||||
|
||||
<article className="environmentCard">
|
||||
<div className="cardTopline">
|
||||
<h3>Artifacts</h3>
|
||||
<Pill tone={latestRuntimeArtifact ? "ok" : "neutral"}>{latestRuntimeArtifact ? "available" : "none"}</Pill>
|
||||
</div>
|
||||
<dl className="facts environmentFacts">
|
||||
<div><dt>Runtime bundle</dt><dd>{text(latestRuntimeArtifact?.name)}</dd></div>
|
||||
<div><dt>Files</dt><dd>{text(latestRuntimeArtifact?.files.length)}</dd></div>
|
||||
<div><dt>Summary</dt><dd>{text(latestRuntimeArtifact?.summaryPath)}</dd></div>
|
||||
<div><dt>Project path</dt><dd>{text(latestRuntimeAudit?.projectPath)}</dd></div>
|
||||
</dl>
|
||||
<PathList title="Search roots" items={searchRoots} />
|
||||
<code title={latestRuntimeArtifact?.path}>{text(latestRuntimeArtifact?.path)}</code>
|
||||
</article>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section className="statusGrid" aria-label="Coordinator summary">
|
||||
<Panel title="Recommendation" icon={<ClipboardCheck size={18} />}>
|
||||
<div className={`actionBanner ${statusClass(coordinator.action ?? crrc.action)}`}>
|
||||
|
|
@ -558,6 +615,19 @@ function ArtifactOutcome({ artifact }: { artifact: ArtifactBundle }) {
|
|||
);
|
||||
}
|
||||
|
||||
function PathList({ title, items }: { title: string; items: string[] }) {
|
||||
if (!items.length) return null;
|
||||
return (
|
||||
<div className="pathList">
|
||||
<strong>{title}</strong>
|
||||
{items.slice(0, 4).map((item) => (
|
||||
<code key={item} title={item}>{item}</code>
|
||||
))}
|
||||
{items.length > 4 && <span>{items.length - 4} more</span>}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
function EmptyState({ label }: { label: string }) {
|
||||
return <p className="emptyState">{label}</p>;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -166,6 +166,10 @@ input {
|
|||
padding: 12px;
|
||||
}
|
||||
|
||||
.notice span {
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.dangerNotice {
|
||||
border-color: #d9b1a4;
|
||||
color: #6b2418;
|
||||
|
|
@ -185,9 +189,12 @@ input {
|
|||
}
|
||||
|
||||
.notice code {
|
||||
display: inline;
|
||||
max-width: min(620px, 70vw);
|
||||
display: inline-block;
|
||||
max-width: 100%;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
vertical-align: bottom;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.statusGrid {
|
||||
|
|
@ -304,6 +311,48 @@ dd {
|
|||
gap: 12px;
|
||||
}
|
||||
|
||||
.environmentGrid {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.75fr) minmax(300px, 0.9fr);
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
.environmentCard {
|
||||
min-width: 0;
|
||||
border: 1px solid #d9ded5;
|
||||
border-radius: 8px;
|
||||
padding: 12px;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.environmentFacts {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
}
|
||||
|
||||
.environmentNote {
|
||||
margin-top: 10px;
|
||||
color: #3e493f;
|
||||
font-size: 0.88rem;
|
||||
line-height: 1.42;
|
||||
}
|
||||
|
||||
.pathList {
|
||||
display: grid;
|
||||
gap: 5px;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.pathList strong {
|
||||
color: #667168;
|
||||
font-size: 0.72rem;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.pathList span {
|
||||
color: #667168;
|
||||
font-size: 0.78rem;
|
||||
}
|
||||
|
||||
.laneCard,
|
||||
.findingCard,
|
||||
.jobRow {
|
||||
|
|
@ -418,6 +467,10 @@ code {
|
|||
.cardGrid {
|
||||
grid-template-columns: repeat(2, minmax(180px, 1fr));
|
||||
}
|
||||
|
||||
.environmentGrid {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
|
|
|
|||
|
|
@ -44,8 +44,22 @@ export interface ArtifactBundle {
|
|||
runtimeAudit?: {
|
||||
resultPath: string;
|
||||
status: string;
|
||||
projectPath?: string;
|
||||
projectVersion?: string;
|
||||
editorPath?: string;
|
||||
note?: string;
|
||||
editorBridge?: {
|
||||
exists: boolean;
|
||||
path?: string;
|
||||
relativePath?: string;
|
||||
executeMethod?: string;
|
||||
};
|
||||
installedEditors?: Array<{
|
||||
version?: string;
|
||||
editorPath?: string;
|
||||
}>;
|
||||
candidatePaths?: string[];
|
||||
searchRoots?: string[];
|
||||
};
|
||||
modifiedMillis?: number;
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue