mirror of
https://github.com/samsonjs/vibetunnel.git
synced 2026-04-27 15:17:38 +00:00
Make the session exited clearer
This commit is contained in:
parent
3758e2d375
commit
3c7b2855d3
2 changed files with 21 additions and 5 deletions
|
|
@ -1222,6 +1222,7 @@ export class SessionView extends LitElement {
|
||||||
<!-- Terminal Component -->
|
<!-- Terminal Component -->
|
||||||
<vibe-terminal
|
<vibe-terminal
|
||||||
.sessionId=${this.session?.id || ''}
|
.sessionId=${this.session?.id || ''}
|
||||||
|
.sessionStatus=${this.session?.status || 'running'}
|
||||||
.cols=${80}
|
.cols=${80}
|
||||||
.rows=${24}
|
.rows=${24}
|
||||||
.fontSize=${this.terminalFontSize}
|
.fontSize=${this.terminalFontSize}
|
||||||
|
|
@ -1231,6 +1232,21 @@ export class SessionView extends LitElement {
|
||||||
></vibe-terminal>
|
></vibe-terminal>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Floating Session Exited Banner (outside terminal container to avoid filter effects) -->
|
||||||
|
${this.session?.status === 'exited'
|
||||||
|
? html`
|
||||||
|
<div
|
||||||
|
class="absolute inset-0 flex items-center justify-center pointer-events-none z-50"
|
||||||
|
>
|
||||||
|
<div
|
||||||
|
class="bg-dark-bg-secondary border border-dark-border ${this.getStatusColor()} font-medium text-sm tracking-wide px-4 py-2 rounded-lg shadow-lg"
|
||||||
|
>
|
||||||
|
SESSION EXITED
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
`
|
||||||
|
: ''}
|
||||||
|
|
||||||
<!-- Mobile Input Controls -->
|
<!-- Mobile Input Controls -->
|
||||||
${this.isMobile && !this.showMobileInput
|
${this.isMobile && !this.showMobileInput
|
||||||
? html`
|
? html`
|
||||||
|
|
|
||||||
|
|
@ -25,6 +25,7 @@ export class Terminal extends LitElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
@property({ type: String }) sessionId = '';
|
@property({ type: String }) sessionId = '';
|
||||||
|
@property({ type: String }) sessionStatus = 'running'; // Track session status for cursor control
|
||||||
@property({ type: Number }) cols = 80;
|
@property({ type: Number }) cols = 80;
|
||||||
@property({ type: Number }) rows = 24;
|
@property({ type: Number }) rows = 24;
|
||||||
@property({ type: Number }) fontSize = 14;
|
@property({ type: Number }) fontSize = 14;
|
||||||
|
|
@ -700,11 +701,10 @@ export class Terminal extends LitElement {
|
||||||
|
|
||||||
// Check if cursor is on this line (relative to viewport)
|
// Check if cursor is on this line (relative to viewport)
|
||||||
const isCursorLine = row === cursorY;
|
const isCursorLine = row === cursorY;
|
||||||
const lineContent = this.renderLine(
|
// Hide cursor for exited sessions or when explicitly disabled via ANSI escape sequences
|
||||||
line,
|
const shouldShowCursor =
|
||||||
cell,
|
isCursorLine && this.cursorVisible && this.sessionStatus !== 'exited';
|
||||||
isCursorLine && this.cursorVisible ? cursorX : -1
|
const lineContent = this.renderLine(line, cell, shouldShowCursor ? cursorX : -1);
|
||||||
);
|
|
||||||
|
|
||||||
html += `<div class="terminal-line"${style}>${lineContent || ''}</div>`;
|
html += `<div class="terminal-line"${style}>${lineContent || ''}</div>`;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue