Files
Claude-Code-Workflow/ccw/src/templates/dashboard-css/02-session.css
catlog22 2fffe78dc9 fix(multi-cli): complete solution details display in summary tab (#98)
Fixed issue where multi-CLI planning solution cards only showed count,
feasibility, effort, and risk badges but had empty content area.

Changes:
- Enhanced renderMultiCliSummaryContent() to extract and display all solution fields
  - Solution name (name/title)
  - Feasibility score (feasibility)
  - Effort level (effort)
  - Risk level (risk)
  - Summary/description (summary)
  - Pros list (pros)
  - Cons list (cons)

- Added CSS styles for solution cards
  - .solution-details, .details-label, .details-list
  - .solution-header, .solution-title-row, .solution-badges
  - .badge with variants for feasibility/effort/risk

- Fixed related issues:
  - Added multiCliPlan support to backend data structures
  - Exposed liteTaskDataStore to window for global access
  - Fixed header left-alignment in detail pages
  - Added 'active' class to tab content for visibility

Files modified:
- ccw/src/templates/dashboard-js/views/lite-tasks.js
- ccw/src/templates/dashboard-css/04-lite-tasks.css
- ccw/src/core/server.ts
- ccw/src/core/routes/system-routes.ts
- ccw/src/templates/dashboard-js/state.js
- ccw/src/templates/dashboard-css/02-session.css
- ccw/src/config/litellm-api-config-manager.ts (fix homedir import)

Closes #98
2026-01-22 15:30:35 +08:00

832 lines
16 KiB
CSS

/* ===================================
Session Cards (used by dashboard.js)
=================================== */
.sessions-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
gap: 1rem;
}
.session-card {
background: hsl(var(--card));
border: 1px solid hsl(var(--border));
border-radius: 0.5rem;
padding: 1rem;
cursor: pointer;
transition: all 0.2s ease;
}
.session-card:hover {
box-shadow: 0 4px 12px rgb(0 0 0 / 0.1);
transform: translateY(-2px);
}
.session-header {
display: flex;
justify-content: space-between;
align-items: flex-start;
margin-bottom: 0.75rem;
}
.session-title {
font-weight: 600;
font-size: 0.9rem;
color: hsl(var(--foreground));
word-break: break-word;
}
.session-badges {
display: flex;
gap: 0.5rem;
flex-shrink: 0;
}
.session-status {
font-size: 0.65rem;
font-weight: 600;
padding: 0.2rem 0.5rem;
border-radius: 9999px;
text-transform: uppercase;
}
.session-status.active {
background: hsl(var(--success-light));
color: hsl(var(--success));
}
.session-status.archived {
background: hsl(var(--muted));
color: hsl(var(--muted-foreground));
}
.session-status.planning {
background: hsl(260 70% 90%);
color: hsl(260 70% 45%);
animation: planning-pulse 2s ease-in-out infinite;
}
@keyframes planning-pulse {
0%, 100% { opacity: 1; }
50% { opacity: 0.7; }
}
/* Planning card style - dashed border with subtle animation */
.session-card.planning {
border: 2px dashed hsl(260 70% 60%);
background: linear-gradient(135deg, hsl(var(--card)) 0%, hsl(260 70% 97%) 100%);
}
.session-card.planning:hover {
border-color: hsl(260 70% 50%);
box-shadow: 0 4px 12px hsl(260 70% 50% / 0.2);
}
.session-type-badge {
font-size: 0.65rem;
font-weight: 500;
padding: 0.2rem 0.5rem;
border-radius: 9999px;
background: hsl(var(--accent));
color: hsl(var(--accent-foreground));
text-transform: uppercase;
}
.session-type-badge.review {
background: hsl(var(--warning-light));
color: hsl(var(--warning));
}
.session-type-badge.test {
background: hsl(220 80% 90%);
color: hsl(220 80% 40%);
}
/* Session Status Badge (used in detail page header) */
.session-status-badge {
font-size: 0.7rem;
font-weight: 500;
padding: 0.25rem 0.625rem;
border-radius: 0.25rem;
text-transform: lowercase;
}
.session-status-badge.plan_generated,
.session-status-badge.converged,
.session-status-badge.completed,
.session-status-badge.decided {
background: hsl(var(--success-light, 142 70% 95%));
color: hsl(var(--success, 142 70% 45%));
}
.session-status-badge.analyzing,
.session-status-badge.debating {
background: hsl(var(--warning-light, 45 90% 95%));
color: hsl(var(--warning, 45 90% 40%));
}
.session-status-badge.initialized,
.session-status-badge.exploring {
background: hsl(var(--info-light, 220 80% 95%));
color: hsl(var(--info, 220 80% 55%));
}
.session-status-badge.blocked,
.session-status-badge.conflict {
background: hsl(var(--destructive) / 0.1);
color: hsl(var(--destructive));
}
.session-status-badge.pending {
background: hsl(var(--muted));
color: hsl(var(--muted-foreground));
}
/* Status Badge Colors (used in card list meta) */
.session-meta-item.status-badge.success {
background: hsl(var(--success-light, 142 70% 95%));
color: hsl(var(--success, 142 70% 45%));
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
font-weight: 500;
}
.session-meta-item.status-badge.warning {
background: hsl(var(--warning-light, 45 90% 95%));
color: hsl(var(--warning, 45 90% 40%));
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
font-weight: 500;
}
.session-meta-item.status-badge.info {
background: hsl(var(--info-light, 220 80% 95%));
color: hsl(var(--info, 220 80% 55%));
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
font-weight: 500;
}
.session-meta-item.status-badge.error {
background: hsl(var(--destructive) / 0.1);
color: hsl(var(--destructive));
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
font-weight: 500;
}
.session-meta-item.status-badge.default {
background: hsl(var(--muted));
color: hsl(var(--muted-foreground));
padding: 0.25rem 0.5rem;
border-radius: 0.25rem;
font-weight: 500;
}
.session-body {
display: flex;
flex-direction: column;
gap: 0.75rem;
}
.session-meta {
display: flex;
gap: 1rem;
font-size: 0.8rem;
color: hsl(var(--muted-foreground));
}
.session-meta-item {
display: flex;
align-items: center;
gap: 0.25rem;
}
.progress-container {
display: flex;
flex-direction: column;
gap: 0.25rem;
}
.progress-label {
font-size: 0.75rem;
color: hsl(var(--muted-foreground));
}
.progress-bar-wrapper {
display: flex;
align-items: center;
gap: 0.75rem;
}
.progress-bar {
flex: 1;
height: 6px;
background: hsl(var(--muted));
border-radius: 3px;
overflow: hidden;
}
.progress-fill {
height: 100%;
background: linear-gradient(90deg, hsl(var(--primary)), hsl(var(--success)));
border-radius: 3px;
transition: width 0.3s ease;
}
.progress-text {
font-size: 0.75rem;
color: hsl(var(--muted-foreground));
white-space: nowrap;
}
/* Empty state */
.empty-state {
text-align: center;
padding: 3rem;
color: hsl(var(--muted-foreground));
}
.empty-state-icon {
font-size: 3rem;
margin-bottom: 1rem;
opacity: 0.5;
}
/* Session detail page */
.session-detail-header {
margin-bottom: 1.5rem;
}
.session-detail-title {
font-size: 1.5rem;
font-weight: 600;
color: hsl(var(--foreground));
margin-bottom: 0.5rem;
}
.session-detail-meta {
display: flex;
gap: 1rem;
flex-wrap: wrap;
font-size: 0.875rem;
color: hsl(var(--muted-foreground));
}
.task-list {
display: flex;
flex-direction: column;
gap: 0.5rem;
}
.task-item {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.75rem 1rem;
background: hsl(var(--card));
border: 1px solid hsl(var(--border));
border-radius: 0.5rem;
cursor: pointer;
transition: all 0.15s ease;
}
.task-item:hover {
background: hsl(var(--hover));
}
.task-item.completed {
border-left: 3px solid hsl(var(--success));
opacity: 0.8;
}
.task-item.in_progress {
border-left: 3px solid hsl(var(--warning));
}
.task-item.pending {
border-left: 3px solid hsl(var(--muted-foreground));
}
.task-checkbox {
width: 1.25rem;
height: 1.25rem;
border-radius: 50%;
border: 2px solid hsl(var(--border));
display: flex;
align-items: center;
justify-content: center;
font-size: 0.7rem;
font-weight: bold;
flex-shrink: 0;
}
.task-item.completed .task-checkbox {
background: hsl(var(--success));
border-color: hsl(var(--success));
color: white;
}
.task-item.completed .task-checkbox::after {
content: '✓';
}
.task-item.in_progress .task-checkbox {
border-color: hsl(var(--warning));
color: hsl(var(--warning));
}
.task-item.in_progress .task-checkbox::after {
content: '⟳';
}
.task-title {
flex: 1;
font-size: 0.875rem;
color: hsl(var(--foreground));
}
.task-id {
font-size: 0.75rem;
font-family: var(--font-mono);
color: hsl(var(--muted-foreground));
}
/* Back button */
.back-button {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.5rem 1rem;
background: hsl(var(--muted));
border: none;
border-radius: 0.375rem;
font-size: 0.875rem;
color: hsl(var(--foreground));
cursor: pointer;
transition: background 0.15s;
margin-bottom: 1rem;
}
.back-button:hover {
background: hsl(var(--hover));
}
/* ===================================
Path Dropdown Menu
=================================== */
.path-menu {
min-width: 320px;
max-height: 400px;
overflow-y: auto;
}
.path-menu .path-item {
display: flex;
align-items: center;
gap: 0.75rem;
padding: 0.75rem 1rem;
cursor: pointer;
transition: background 0.15s;
border-bottom: 1px solid hsl(var(--border));
}
.path-menu .path-item:hover {
background: hsl(var(--hover));
}
.path-menu .path-item:last-child {
border-bottom: none;
}
.path-menu .path-icon {
font-size: 1.25rem;
flex-shrink: 0;
}
.path-menu .path-text {
flex: 1;
font-size: 0.875rem;
color: hsl(var(--foreground));
word-break: break-all;
}
.path-menu .path-item {
display: flex;
align-items: center;
justify-content: space-between;
}
.path-menu .path-text {
cursor: pointer;
}
.path-delete-btn {
width: 20px;
height: 20px;
border: none;
background: transparent;
color: hsl(var(--muted-foreground));
font-size: 16px;
font-weight: bold;
cursor: pointer;
border-radius: 4px;
display: flex;
align-items: center;
justify-content: center;
opacity: 0;
transition: opacity 0.15s, background 0.15s, color 0.15s;
flex-shrink: 0;
margin-left: 8px;
}
.path-menu .path-item:hover .path-delete-btn {
opacity: 1;
}
.path-delete-btn:hover {
background: hsl(var(--destructive) / 0.1);
color: hsl(var(--destructive));
}
/* ===================================
Session Detail Page
=================================== */
.session-detail-page {
display: flex;
flex-direction: column;
gap: 1.5rem;
}
.detail-header {
display: flex;
flex-direction: column;
gap: 1rem;
align-items: flex-start;
}
.btn-back {
display: inline-flex;
align-items: center;
gap: 0.5rem;
padding: 0.5rem 1rem;
background: hsl(var(--muted));
border: none;
border-radius: 0.375rem;
font-size: 0.875rem;
color: hsl(var(--foreground));
cursor: pointer;
transition: background 0.15s;
width: fit-content;
}
.btn-back:hover {
background: hsl(var(--hover));
}
.back-icon {
font-size: 1rem;
}
.detail-title-row {
display: flex;
align-items: center;
justify-content: flex-start;
gap: 1rem;
flex-wrap: wrap;
}
.detail-session-id {
font-size: 1.5rem;
font-weight: 600;
color: hsl(var(--foreground));
margin: 0;
word-break: break-word;
}
.detail-badges {
display: flex;
gap: 0.5rem;
}
.detail-info-bar {
display: flex;
flex-wrap: wrap;
gap: 1.5rem;
padding: 1rem;
background: hsl(var(--card));
border: 1px solid hsl(var(--border));
border-radius: 0.5rem;
}
.info-item {
display: flex;
gap: 0.5rem;
font-size: 0.875rem;
}
.info-label {
color: hsl(var(--muted-foreground));
}
.info-value {
color: hsl(var(--foreground));
font-weight: 500;
}
/* Detail Tabs */
.detail-tabs {
display: flex;
gap: 0.25rem;
border-bottom: 1px solid hsl(var(--border));
overflow-x: auto;
}
.detail-tab {
display: flex;
align-items: center;
gap: 0.5rem;
padding: 0.75rem 1rem;
background: none;
border: none;
border-bottom: 2px solid transparent;
font-size: 0.875rem;
color: hsl(var(--muted-foreground));
cursor: pointer;
transition: all 0.15s;
white-space: nowrap;
}
.detail-tab:hover {
color: hsl(var(--foreground));
background: hsl(var(--hover));
}
.detail-tab.active {
color: hsl(var(--primary));
border-bottom-color: hsl(var(--primary));
}
.tab-icon {
font-size: 1rem;
}
.tab-count {
padding: 0.125rem 0.5rem;
background: hsl(var(--muted));
border-radius: 9999px;
font-size: 0.75rem;
font-weight: 500;
}
.detail-tab.active .tab-count {
background: hsl(var(--primary));
color: hsl(var(--primary-foreground));
}
.detail-tab-content {
min-height: 300px;
}
/* Task Stats */
.task-stats {
display: flex;
gap: 1rem;
margin-bottom: 1rem;
}
.task-stat {
display: flex;
align-items: center;
gap: 0.5rem;
padding: 0.5rem 1rem;
background: hsl(var(--card));
border: 1px solid hsl(var(--border));
border-radius: 0.375rem;
font-size: 0.875rem;
}
.task-stat.completed { border-left: 3px solid hsl(var(--success)); }
.task-stat.in-progress { border-left: 3px solid hsl(var(--warning)); }
.task-stat.pending { border-left: 3px solid hsl(var(--muted-foreground)); }
.stat-count {
font-weight: 600;
color: hsl(var(--foreground));
}
.stat-label {
color: hsl(var(--muted-foreground));
}
/* Tab Loading */
.tab-loading {
display: flex;
align-items: center;
justify-content: center;
padding: 3rem;
color: hsl(var(--muted-foreground));
font-size: 0.875rem;
}
/* Context/Summary Content */
.context-content,
.summary-content,
.impl-plan-content,
.review-content {
padding: 1rem;
background: hsl(var(--card));
border: 1px solid hsl(var(--border));
border-radius: 0.5rem;
}
.context-section,
.summary-section,
.plan-section {
margin-bottom: 1.5rem;
}
.context-section:last-child,
.summary-section:last-child,
.plan-section:last-child {
margin-bottom: 0;
}
/* Plan Tab Styles */
.plan-tab-content {
padding: 1rem 0;
}
.plan-section-title {
font-size: 1rem;
font-weight: 600;
color: hsl(var(--foreground));
margin-bottom: 0.75rem;
display: flex;
align-items: center;
gap: 0.5rem;
}
.plan-summary-text,
.plan-approach-text {
color: hsl(var(--foreground));
line-height: 1.6;
padding: 0.75rem 1rem;
background: hsl(var(--muted));
border-radius: 0.5rem;
border-left: 3px solid hsl(var(--primary));
}
.plan-meta-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 0.75rem;
}
.plan-meta-grid .meta-item {
padding: 0.5rem 0.75rem;
background: hsl(var(--muted));
border-radius: 0.25rem;
font-size: 0.875rem;
}
.plan-meta-grid .meta-label {
font-weight: 600;
color: hsl(var(--muted-foreground));
}
/* Lite Task Detail Page */
.lite-task-detail-page .detail-header {
margin-bottom: 1.5rem;
}
.lite-task-detail-page .task-toolbar {
margin-bottom: 1rem;
}
.lite-task-detail-page .task-stat {
font-size: 0.8rem;
}
/* Context Tab Content */
.context-tab-content {
padding: 1rem 0;
}
.context-tab-content .context-section h4 {
font-size: 0.9rem;
font-weight: 600;
color: hsl(var(--foreground));
margin-bottom: 0.5rem;
}
.context-tab-content .context-section p {
color: hsl(var(--foreground));
line-height: 1.6;
}
.section-title {
font-size: 1rem;
font-weight: 600;
color: hsl(var(--foreground));
margin-bottom: 0.75rem;
display: flex;
align-items: center;
gap: 0.5rem;
}
.file-list {
display: flex;
flex-direction: column;
gap: 0.25rem;
}
.file-item {
padding: 0.5rem 0.75rem;
background: hsl(var(--muted));
border-radius: 0.25rem;
font-family: var(--font-mono);
font-size: 0.8rem;
color: hsl(var(--foreground));
}
/* Code blocks */
pre, code {
font-family: var(--font-mono);
background: hsl(var(--muted));
border-radius: 0.25rem;
}
pre {
padding: 1rem;
overflow-x: auto;
font-size: 0.8rem;
line-height: 1.5;
}
code {
padding: 0.125rem 0.25rem;
font-size: 0.85em;
}
/* Review Findings */
.findings-list {
display: flex;
flex-direction: column;
gap: 0.75rem;
}
.finding-item {
padding: 1rem;
background: hsl(var(--card));
border: 1px solid hsl(var(--border));
border-radius: 0.5rem;
border-left: 3px solid hsl(var(--border));
}
.finding-item.critical { border-left-color: hsl(0 70% 50%); }
.finding-item.high { border-left-color: hsl(25 90% 55%); }
.finding-item.medium { border-left-color: hsl(45 90% 50%); }
.finding-item.low { border-left-color: hsl(var(--success)); }
.finding-header {
display: flex;
justify-content: space-between;
align-items: flex-start;
margin-bottom: 0.5rem;
}
.finding-title {
font-weight: 600;
color: hsl(var(--foreground));
}
.severity-badge {
padding: 0.125rem 0.5rem;
border-radius: 9999px;
font-size: 0.7rem;
font-weight: 600;
text-transform: uppercase;
}
.severity-badge.critical { background: hsl(0 70% 90%); color: hsl(0 70% 40%); }
.severity-badge.high { background: hsl(25 90% 90%); color: hsl(25 90% 35%); }
.severity-badge.medium { background: hsl(45 90% 90%); color: hsl(45 90% 30%); }
.severity-badge.low { background: hsl(var(--success-light)); color: hsl(var(--success)); }
.finding-description {
font-size: 0.875rem;
color: hsl(var(--muted-foreground));
line-height: 1.5;
}
.finding-location {
margin-top: 0.5rem;
font-size: 0.75rem;
font-family: var(--font-mono);
color: hsl(var(--muted-foreground));
}