feat: OpenCode-style session management implementation
This commit is contained in:
@@ -1096,3 +1096,352 @@ body {
|
||||
font-size: 14px;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
SESSIONS VIEW - History Browser Styles
|
||||
============================================ */
|
||||
|
||||
/* Sessions List Container */
|
||||
.sessions-list {
|
||||
overflow-y: auto;
|
||||
max-height: calc(100vh - 200px);
|
||||
padding: 12px;
|
||||
}
|
||||
|
||||
/* Session List Items */
|
||||
.session-item {
|
||||
background: #1a1a1a;
|
||||
border: 1px solid #333;
|
||||
border-radius: 8px;
|
||||
padding: 12px 16px;
|
||||
margin-bottom: 8px;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s ease;
|
||||
}
|
||||
|
||||
.session-item:hover {
|
||||
background: #252525;
|
||||
border-color: #4a9eff;
|
||||
transform: translateX(4px);
|
||||
}
|
||||
|
||||
.session-item.historical {
|
||||
border-left: 3px solid #888;
|
||||
}
|
||||
|
||||
.session-item.historical:hover {
|
||||
border-left-color: #4a9eff;
|
||||
}
|
||||
|
||||
/* Session Header */
|
||||
.session-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.session-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.session-id {
|
||||
font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: #e0e0e0;
|
||||
}
|
||||
|
||||
/* Session Status Badges */
|
||||
.session-status {
|
||||
display: inline-block;
|
||||
padding: 4px 8px;
|
||||
border-radius: 4px;
|
||||
font-size: 11px;
|
||||
font-weight: 600;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.session-status.running {
|
||||
background: rgba(81, 207, 102, 0.2);
|
||||
color: #51cf66;
|
||||
border: 1px solid rgba(81, 207, 102, 0.3);
|
||||
}
|
||||
|
||||
.session-status.stopped {
|
||||
background: rgba(136, 136, 136, 0.2);
|
||||
color: #888;
|
||||
border: 1px solid rgba(136, 136, 136, 0.3);
|
||||
}
|
||||
|
||||
.session-time {
|
||||
font-size: 12px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
/* Session Meta */
|
||||
.session-meta {
|
||||
font-size: 12px;
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
.session-path {
|
||||
margin-bottom: 4px;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.session-stats {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
font-size: 11px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
/* Empty/Error States */
|
||||
.empty-state, .error-state {
|
||||
text-align: center;
|
||||
padding: 40px 20px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
.empty-icon, .error-icon {
|
||||
font-size: 48px;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.error-message {
|
||||
font-size: 13px;
|
||||
color: #ff6b6b;
|
||||
margin: 8px 0 16px 0;
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
SESSION DETAIL CARD
|
||||
============================================ */
|
||||
|
||||
.session-detail-card {
|
||||
background: #1a1a1a;
|
||||
border-radius: 12px;
|
||||
padding: 24px;
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.session-detail-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: flex-start;
|
||||
margin-bottom: 24px;
|
||||
padding-bottom: 20px;
|
||||
border-bottom: 1px solid #333;
|
||||
}
|
||||
|
||||
.session-title h2 {
|
||||
margin: 0 0 8px 0;
|
||||
font-size: 24px;
|
||||
color: #e0e0e0;
|
||||
}
|
||||
|
||||
.session-status-badge {
|
||||
display: inline-block;
|
||||
padding: 6px 12px;
|
||||
border-radius: 6px;
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.session-status-badge.running {
|
||||
background: rgba(81, 207, 102, 0.2);
|
||||
color: #51cf66;
|
||||
}
|
||||
|
||||
.session-status-badge.stopped {
|
||||
background: rgba(136, 136, 136, 0.2);
|
||||
color: #888;
|
||||
}
|
||||
|
||||
.session-detail-actions {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.session-detail-actions .btn-primary {
|
||||
background: linear-gradient(135deg, #4a9eff 0%, #a78bfa 100%);
|
||||
border: none;
|
||||
padding: 10px 20px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.session-detail-actions .btn-secondary {
|
||||
background: #2a2a2a;
|
||||
border: 1px solid #444;
|
||||
padding: 10px 16px;
|
||||
}
|
||||
|
||||
.session-detail-actions .btn-danger {
|
||||
background: rgba(255, 107, 107, 0.2);
|
||||
border: 1px solid rgba(255, 107, 107, 0.3);
|
||||
color: #ff6b6b;
|
||||
padding: 10px 16px;
|
||||
}
|
||||
|
||||
.session-detail-actions .btn-danger:hover {
|
||||
background: rgba(255, 107, 107, 0.3);
|
||||
}
|
||||
|
||||
.session-detail-meta {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
gap: 12px;
|
||||
margin-bottom: 24px;
|
||||
padding: 16px;
|
||||
background: #0d0d0d;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.meta-row {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.meta-label {
|
||||
color: #888;
|
||||
font-weight: 600;
|
||||
min-width: 120px;
|
||||
}
|
||||
|
||||
.meta-value {
|
||||
color: #e0e0e0;
|
||||
word-break: break-all;
|
||||
}
|
||||
|
||||
.session-context {
|
||||
margin-bottom: 24px;
|
||||
padding: 16px;
|
||||
background: #0d0d0d;
|
||||
border-radius: 8px;
|
||||
}
|
||||
|
||||
.session-context h3 {
|
||||
margin: 0 0 12px 0;
|
||||
font-size: 14px;
|
||||
color: #e0e0e0;
|
||||
}
|
||||
|
||||
.context-bar {
|
||||
width: 100%;
|
||||
height: 8px;
|
||||
background: #333;
|
||||
border-radius: 4px;
|
||||
overflow: hidden;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.context-fill {
|
||||
height: 100%;
|
||||
background: linear-gradient(90deg, #4a9eff 0%, #a78bfa 100%);
|
||||
transition: width 0.3s ease;
|
||||
}
|
||||
|
||||
.context-stats {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 12px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
.session-output-preview h3 {
|
||||
margin: 0 0 16px 0;
|
||||
font-size: 16px;
|
||||
color: #e0e0e0;
|
||||
}
|
||||
|
||||
.output-scroll-area {
|
||||
max-height: 400px;
|
||||
overflow-y: auto;
|
||||
background: #0d0d0d;
|
||||
border: 1px solid #333;
|
||||
border-radius: 8px;
|
||||
padding: 12px;
|
||||
}
|
||||
|
||||
.output-entry {
|
||||
margin-bottom: 12px;
|
||||
padding-bottom: 12px;
|
||||
border-bottom: 1px solid #252525;
|
||||
}
|
||||
|
||||
.output-entry:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.output-header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
|
||||
.output-type {
|
||||
display: inline-block;
|
||||
padding: 2px 8px;
|
||||
background: #252525;
|
||||
color: #888;
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
text-transform: uppercase;
|
||||
border-radius: 3px;
|
||||
}
|
||||
|
||||
.output-time {
|
||||
font-size: 11px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.output-content {
|
||||
font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
|
||||
font-size: 12px;
|
||||
color: #aaa;
|
||||
white-space: pre-wrap;
|
||||
word-break: break-all;
|
||||
line-height: 1.5;
|
||||
}
|
||||
|
||||
.no-output {
|
||||
text-align: center;
|
||||
padding: 40px;
|
||||
color: #666;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.output-truncated {
|
||||
text-align: center;
|
||||
padding: 12px;
|
||||
color: #4a9eff;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
/* Responsive */
|
||||
@media (max-width: 768px) {
|
||||
.session-detail-header {
|
||||
flex-direction: column;
|
||||
gap: 16px;
|
||||
}
|
||||
|
||||
.session-detail-actions {
|
||||
width: 100%;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.session-detail-actions button {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.session-detail-meta {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user