feat: add an inline deploy-progress style for the stack detail (#1355)

* feat: add an inline deploy-progress style for the stack detail

Deploy progress gains a presentation choice under Settings > Appearance >
Display: Modal (the default centered overlay) or Inline. In Inline style a
compact status band on the stack detail shows the running operation, its
elapsed time, the live phase, the latest output line, and the post-update
health gate result. A "View output" button opens the full log modal on
demand, a dismiss control clears the band, and the band auto-clears a few
seconds after a clean completion.

The live progress socket is lifted to an always-mounted owner so the band
streams without the modal; the default Modal style is unchanged. Operations
carry their node so a band never bleeds onto a same-named stack on another
node.

The stack detail's redundant "CONTAINERS" section heading is removed; the
band reserves that vertical space.

* fix: keep inline deploy progress reachable off the stack detail

Review of the inline presentation found a gap: a failed operation, an App
Store install, or navigating away leaves the inline session with no visible
surface, since the band only renders on the operation's own stack detail.
Restore the minimized pill as the inline fallback, shown only when the band
is not covering the session, so there is always a click-through to the log
without ever overlapping the band. Closing the modal for a failed op now
ends the session (the band has stepped aside) instead of only hiding it.

Also document the unsupported mid-operation style switch, and refresh the
deploy-progress, settings, appearance, and app-store docs for the renamed
"Deploy progress" setting and the Modal/Inline choice.
This commit is contained in:
Anso
2026-06-11 10:33:57 -04:00
committed by GitHub
parent 38aabe7064
commit e20f1fe415
30 changed files with 1258 additions and 73 deletions
@@ -1,29 +1,43 @@
import { useEffect, useState } from 'react';
import { useDeployFeedback } from '@/context/DeployFeedbackContext';
import { useDeployFeedbackStyle } from '@/hooks/use-deploy-feedback-style';
import TerminalComponent from './Terminal';
import { DeployFeedbackModal } from './DeployFeedbackModal';
import { DeployFeedbackPill } from './DeployFeedbackPill';
export function DeployFeedbackPortal() {
const [isMinimized, setIsMinimized] = useState(false);
const { panelState } = useDeployFeedback();
useEffect(() => {
if (!panelState.isOpen) {
// eslint-disable-next-line react-hooks/set-state-in-effect
setIsMinimized(false);
}
}, [panelState.isOpen]);
const { panelState, minimized, setMinimized, bannerActive, onTerminalReady, onTerminalError, onMessage } = useDeployFeedback();
const [style] = useDeployFeedbackStyle();
return (
<>
<DeployFeedbackModal
isMinimized={isMinimized}
onMinimize={() => setIsMinimized(true)}
isMinimized={minimized}
onMinimize={() => setMinimized(true)}
/>
{/* The pill is the minimized surface. In Modal style it shows whenever the
modal is minimized. In Inline style the in-page banner is the surface,
so the pill only fills in when the banner is not covering the session:
an App Store install, after navigating away from the stack, or a failed
op the banner steps aside for. This keeps a click-through to the log in
every case without ever overlapping the banner. */}
<DeployFeedbackPill
isVisible={panelState.isOpen && isMinimized}
onExpand={() => setIsMinimized(false)}
isVisible={panelState.isOpen && minimized && (style === 'modal' || !bannerActive)}
onExpand={() => setMinimized(false)}
/>
{/* Inline style streams without the modal: the modal owns the terminal in
Modal style, but in Inline style the modal stays closed, so mount the
single progress terminal here (hidden) to feed logRows to the banner.
Exactly one terminal owns the per-session socket at a time. */}
{style === 'inline' && panelState.isOpen && (
<div aria-hidden className="h-0 overflow-hidden">
<TerminalComponent
deploySessionId={panelState.deploySessionId}
onReady={onTerminalReady}
onError={onTerminalError}
onMessage={onMessage}
/>
</div>
)}
</>
);
}