feat(web): /machine dev-box page with status, terminal, and home file browser

This commit is contained in:
Gabriel Brown
2026-07-11 12:57:13 -04:00
parent ea56b29453
commit 33e7732566
6 changed files with 645 additions and 6 deletions
@@ -75,12 +75,14 @@ export const XtermSession = ({
sessionKey,
waitingLabel,
copyOnSelect,
label = 'workspace shell',
}: {
active: boolean;
tokenUrl: string;
sessionKey: string;
waitingLabel?: string;
copyOnSelect?: boolean;
label?: string;
}) => {
const containerRef = useRef<HTMLDivElement>(null);
const termRef = useRef<Terminal | null>(null);
@@ -183,11 +185,9 @@ export const XtermSession = ({
sendResize,
fontsReady: document.fonts.ready,
loadNerdFont: () =>
document.fonts
.load("16px 'Symbols Nerd Font Mono'", '')
.then(() => {
if (!isAborted()) term.refresh(0, term.rows - 1);
}),
document.fonts.load("16px 'Symbols Nerd Font Mono'", '').then(() => {
if (!isAborted()) term.refresh(0, term.rows - 1);
}),
raf: (cb) => requestAnimationFrame(cb),
isAborted,
});
@@ -243,7 +243,7 @@ export const XtermSession = ({
<div className='border-border flex h-10 flex-none items-center justify-between gap-3 border-b px-3'>
<p className='text-muted-foreground text-xs'>
{status === 'connected'
? 'Connected · workspace shell'
? `Connected · ${label}`
: status === 'connecting'
? 'Connecting…'
: status === 'closed'