feat: v1.1.2 — dashboard redesign, pve CLI tool, sidebar cluster selector
This commit is contained in:
@@ -2698,3 +2698,640 @@ body {
|
||||
background: rgba(102,126,234,.2);
|
||||
color: #667eea;
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
Sidebar - Cluster Selector Section
|
||||
============================================ */
|
||||
|
||||
.sidebar-cluster-section {
|
||||
padding: 0 var(--spacing-md) var(--spacing-md);
|
||||
border-bottom: 1px solid rgba(100,100,150,0.15);
|
||||
margin-bottom: var(--spacing-sm);
|
||||
}
|
||||
|
||||
.sidebar-cluster-label {
|
||||
font-size: 0.625rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.1em;
|
||||
color: rgba(160,160,181,0.5);
|
||||
text-transform: uppercase;
|
||||
margin-bottom: 0.35rem;
|
||||
padding-left: 2px;
|
||||
}
|
||||
|
||||
.cluster-selector-btn {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
width: 100%;
|
||||
background: rgba(102,126,234,0.1);
|
||||
border: 1px solid rgba(102,126,234,0.2);
|
||||
border-radius: var(--radius-md);
|
||||
color: #c8ccf5;
|
||||
font-size: 0.875rem;
|
||||
font-weight: 600;
|
||||
padding: 8px 12px;
|
||||
cursor: pointer;
|
||||
transition: all var(--transition-fast);
|
||||
text-align: left;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.cluster-selector-btn:hover {
|
||||
background: rgba(102,126,234,0.18);
|
||||
border-color: rgba(102,126,234,0.4);
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.cluster-name-text {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.sidebar.collapsed .sidebar-cluster-section {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
Page Subtitle & Header Status
|
||||
============================================ */
|
||||
|
||||
.page-subtitle {
|
||||
font-size: 0.8125rem;
|
||||
color: var(--text-muted);
|
||||
margin-top: 2px;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.status-chip {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 6px 14px;
|
||||
border-radius: var(--radius-full);
|
||||
font-size: 0.8125rem;
|
||||
font-weight: 600;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.status-chip.status-ok {
|
||||
background: rgba(16,185,129,0.12);
|
||||
color: #10b981;
|
||||
border: 1px solid rgba(16,185,129,0.25);
|
||||
}
|
||||
|
||||
.status-chip.status-warning {
|
||||
background: rgba(249,115,22,0.12);
|
||||
color: #f97316;
|
||||
border: 1px solid rgba(249,115,22,0.25);
|
||||
}
|
||||
|
||||
.status-chip.status-error {
|
||||
background: rgba(239,68,68,0.12);
|
||||
color: #ef4444;
|
||||
border: 1px solid rgba(239,68,68,0.25);
|
||||
}
|
||||
|
||||
.status-chip-dot {
|
||||
width: 7px;
|
||||
height: 7px;
|
||||
border-radius: 50%;
|
||||
background: currentColor;
|
||||
animation: pulse-dot 2.5s ease-in-out infinite;
|
||||
}
|
||||
|
||||
@keyframes pulse-dot {
|
||||
0%, 100% { opacity: 1; transform: scale(1); }
|
||||
50% { opacity: 0.6; transform: scale(0.85); }
|
||||
}
|
||||
|
||||
.header-datetime {
|
||||
font-size: 0.8125rem;
|
||||
color: var(--text-secondary);
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.version-badge {
|
||||
font-size: 0.75rem;
|
||||
font-weight: 600;
|
||||
color: var(--text-muted);
|
||||
padding: 4px 10px;
|
||||
border: 1px solid var(--border-default);
|
||||
border-radius: var(--radius-full);
|
||||
background: var(--bg-surface-hover);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
/* Header title block (title + subtitle stacked) */
|
||||
.header-title-block {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1px;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.header-title-block h2 {
|
||||
margin: 0;
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
Dashboard Stat Cards v2
|
||||
============================================ */
|
||||
|
||||
.stats-grid-5 {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(5, 1fr);
|
||||
gap: var(--spacing-md);
|
||||
margin-bottom: var(--spacing-lg);
|
||||
}
|
||||
|
||||
@media (max-width: 1200px) {
|
||||
.stats-grid-5 { grid-template-columns: repeat(3, 1fr); }
|
||||
}
|
||||
@media (max-width: 768px) {
|
||||
.stats-grid-5 { grid-template-columns: repeat(2, 1fr); gap: var(--spacing-sm); }
|
||||
}
|
||||
@media (max-width: 480px) {
|
||||
.stats-grid-5 { grid-template-columns: 1fr; }
|
||||
}
|
||||
|
||||
.stat-card-v2 {
|
||||
background: var(--glass-bg);
|
||||
backdrop-filter: blur(20px);
|
||||
-webkit-backdrop-filter: blur(20px);
|
||||
border: 1px solid var(--glass-border);
|
||||
border-radius: var(--radius-lg);
|
||||
padding: 1.25rem 1.5rem;
|
||||
transition: border-color var(--transition-fast), transform var(--transition-fast);
|
||||
animation: fadeIn 0.5s ease;
|
||||
}
|
||||
|
||||
.stat-card-v2:hover {
|
||||
border-color: var(--primary);
|
||||
transform: translateY(-2px);
|
||||
}
|
||||
|
||||
.stat-card-lbl {
|
||||
font-size: 0.6875rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.08em;
|
||||
text-transform: uppercase;
|
||||
color: var(--text-muted);
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
.stat-card-val {
|
||||
font-size: 2.5rem;
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
line-height: 1.1;
|
||||
margin-bottom: 0.25rem;
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
.stat-card-sub {
|
||||
font-size: 0.8125rem;
|
||||
color: var(--text-muted);
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
.stat-card-v2.card-alerts .stat-card-val { color: var(--danger); }
|
||||
.stat-card-v2.card-alerts .stat-card-sub { color: var(--warning); }
|
||||
|
||||
/* ============================================
|
||||
Resource Usage Cards (CPU / RAM / Storage)
|
||||
============================================ */
|
||||
|
||||
.resource-cards-row {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: var(--spacing-md);
|
||||
margin-bottom: var(--spacing-lg);
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.resource-cards-row { grid-template-columns: 1fr; }
|
||||
}
|
||||
|
||||
.resource-card {
|
||||
background: var(--glass-bg);
|
||||
backdrop-filter: blur(20px);
|
||||
-webkit-backdrop-filter: blur(20px);
|
||||
border: 1px solid var(--glass-border);
|
||||
border-radius: var(--radius-lg);
|
||||
padding: 1.25rem 1.5rem;
|
||||
animation: fadeIn 0.6s ease;
|
||||
}
|
||||
|
||||
.resource-card-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-bottom: 1.1rem;
|
||||
}
|
||||
|
||||
.resource-card-title {
|
||||
font-size: 0.6875rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.08em;
|
||||
text-transform: uppercase;
|
||||
color: var(--text-muted);
|
||||
}
|
||||
|
||||
.resource-pct-badge {
|
||||
font-size: 1.5rem;
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
.resource-pct-badge.pct-ok { color: #10b981; }
|
||||
.resource-pct-badge.pct-warn { color: #f97316; }
|
||||
.resource-pct-badge.pct-high { color: #ef4444; }
|
||||
|
||||
.resource-mini-chart {
|
||||
height: 90px;
|
||||
width: 100%;
|
||||
margin-bottom: 0.75rem;
|
||||
}
|
||||
|
||||
.resource-progress-bar {
|
||||
height: 6px;
|
||||
background: var(--bg-surface-hover);
|
||||
border-radius: var(--radius-full);
|
||||
overflow: hidden;
|
||||
margin-top: 0.5rem;
|
||||
}
|
||||
|
||||
.resource-progress-fill {
|
||||
height: 100%;
|
||||
border-radius: var(--radius-full);
|
||||
transition: width 0.8s cubic-bezier(0.4,0,0.2,1);
|
||||
}
|
||||
|
||||
.resource-progress-fill.cpu-fill { background: linear-gradient(90deg, #60a5fa, #3b82f6); }
|
||||
.resource-progress-fill.ram-fill { background: linear-gradient(90deg, #a78bfa, #8b5cf6); }
|
||||
.resource-progress-fill.disk-fill { background: linear-gradient(90deg, #34d399, #10b981); }
|
||||
|
||||
/* ============================================
|
||||
Dashboard Main Grid (VM table + Nodes panel)
|
||||
============================================ */
|
||||
|
||||
.dash-main-grid {
|
||||
display: grid;
|
||||
grid-template-columns: 2fr 1fr;
|
||||
gap: var(--spacing-md);
|
||||
margin-bottom: var(--spacing-lg);
|
||||
}
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
.dash-main-grid { grid-template-columns: 1fr; }
|
||||
}
|
||||
|
||||
.dash-section {
|
||||
background: var(--glass-bg);
|
||||
backdrop-filter: blur(20px);
|
||||
-webkit-backdrop-filter: blur(20px);
|
||||
border: 1px solid var(--glass-border);
|
||||
border-radius: var(--radius-lg);
|
||||
overflow: hidden;
|
||||
animation: fadeIn 0.6s ease;
|
||||
}
|
||||
|
||||
.dash-section-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 1rem 1.25rem;
|
||||
border-bottom: 1px solid var(--border-muted);
|
||||
}
|
||||
|
||||
.dash-section-title {
|
||||
font-size: 0.6875rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.08em;
|
||||
text-transform: uppercase;
|
||||
color: var(--text-muted);
|
||||
}
|
||||
|
||||
.dash-section-meta {
|
||||
font-size: 0.75rem;
|
||||
color: var(--text-muted);
|
||||
}
|
||||
|
||||
.dash-section-link {
|
||||
font-size: 0.75rem;
|
||||
color: var(--primary);
|
||||
text-decoration: none;
|
||||
font-weight: 500;
|
||||
transition: opacity var(--transition-fast);
|
||||
}
|
||||
|
||||
.dash-section-link:hover { opacity: 0.75; }
|
||||
|
||||
/* VM Table Compact */
|
||||
.vm-table-compact {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
|
||||
.vm-table-compact th {
|
||||
font-size: 0.6875rem;
|
||||
font-weight: 600;
|
||||
letter-spacing: 0.05em;
|
||||
text-transform: uppercase;
|
||||
color: var(--text-muted);
|
||||
padding: 0.6rem 1.25rem;
|
||||
border-bottom: 1px solid var(--border-muted);
|
||||
text-align: left;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.vm-table-compact td {
|
||||
padding: 0.75rem 1.25rem;
|
||||
border-bottom: 1px solid var(--border-muted);
|
||||
font-size: 0.875rem;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
|
||||
.vm-table-compact tr:last-child td { border-bottom: none; }
|
||||
|
||||
.vm-table-compact tr:hover td {
|
||||
background: var(--bg-surface-hover);
|
||||
}
|
||||
|
||||
.vm-name-cell {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 0.8125rem;
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
|
||||
.vm-node-cell {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 0.75rem;
|
||||
color: var(--text-muted);
|
||||
}
|
||||
|
||||
.vm-metric-cell {
|
||||
font-size: 0.8125rem;
|
||||
font-variant-numeric: tabular-nums;
|
||||
color: var(--text-secondary);
|
||||
}
|
||||
|
||||
.vm-status-badge {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 5px;
|
||||
padding: 4px 10px;
|
||||
border-radius: var(--radius-full);
|
||||
font-size: 0.75rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.vm-status-badge.running {
|
||||
background: rgba(16,185,129,0.15);
|
||||
color: #10b981;
|
||||
}
|
||||
|
||||
.vm-status-badge.stopped {
|
||||
background: rgba(100,100,150,0.15);
|
||||
color: var(--text-muted);
|
||||
}
|
||||
|
||||
.vm-status-badge.warning, .vm-status-badge.paused {
|
||||
background: rgba(249,115,22,0.15);
|
||||
color: #f97316;
|
||||
}
|
||||
|
||||
.vm-status-badge .status-dot-sm {
|
||||
width: 6px;
|
||||
height: 6px;
|
||||
border-radius: 50%;
|
||||
background: currentColor;
|
||||
}
|
||||
|
||||
/* Nodes Panel */
|
||||
.nodes-panel {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.node-item {
|
||||
padding: 0.75rem 1.25rem;
|
||||
border-bottom: 1px solid var(--border-muted);
|
||||
transition: background var(--transition-fast);
|
||||
}
|
||||
|
||||
.node-item:last-child { border-bottom: none; }
|
||||
|
||||
.node-item:hover { background: var(--bg-surface-hover); }
|
||||
|
||||
.node-item-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
|
||||
.node-item-name {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 7px;
|
||||
font-family: var(--font-mono);
|
||||
font-size: 0.8125rem;
|
||||
font-weight: 600;
|
||||
color: var(--text-primary);
|
||||
}
|
||||
|
||||
.node-dot-online {
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-radius: 50%;
|
||||
background: #10b981;
|
||||
box-shadow: 0 0 6px rgba(16,185,129,0.6);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.node-dot-offline {
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-radius: 50%;
|
||||
background: var(--text-muted);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.node-vm-count {
|
||||
font-size: 0.6875rem;
|
||||
color: var(--text-muted);
|
||||
font-weight: 400;
|
||||
font-family: var(--font-sans);
|
||||
}
|
||||
|
||||
.node-bar-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
margin-bottom: 3px;
|
||||
}
|
||||
|
||||
.node-bar-lbl {
|
||||
font-size: 0.6875rem;
|
||||
color: var(--text-muted);
|
||||
width: 30px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.node-bar-wrap {
|
||||
flex: 1;
|
||||
height: 5px;
|
||||
background: var(--bg-surface-hover);
|
||||
border-radius: var(--radius-full);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.node-bar-fill {
|
||||
height: 100%;
|
||||
border-radius: var(--radius-full);
|
||||
transition: width 0.8s cubic-bezier(0.4,0,0.2,1);
|
||||
}
|
||||
|
||||
.node-bar-fill.cpu { background: linear-gradient(90deg, #60a5fa, #3b82f6); }
|
||||
.node-bar-fill.ram { background: linear-gradient(90deg, #a78bfa, #8b5cf6); }
|
||||
|
||||
.node-bar-pct {
|
||||
font-size: 0.6875rem;
|
||||
color: var(--text-muted);
|
||||
width: 30px;
|
||||
text-align: right;
|
||||
flex-shrink: 0;
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
Recent Audit Events
|
||||
============================================ */
|
||||
|
||||
.audit-events-list {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.audit-row {
|
||||
display: grid;
|
||||
grid-template-columns: 70px 80px auto 100px;
|
||||
align-items: center;
|
||||
gap: 1rem;
|
||||
padding: 0.7rem 1.25rem;
|
||||
border-bottom: 1px solid var(--border-muted);
|
||||
font-size: 0.8125rem;
|
||||
transition: background var(--transition-fast);
|
||||
}
|
||||
|
||||
.audit-row:last-child { border-bottom: none; }
|
||||
.audit-row:hover { background: var(--bg-surface-hover); }
|
||||
|
||||
.audit-time {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 0.75rem;
|
||||
color: var(--text-muted);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.audit-user {
|
||||
color: var(--text-secondary);
|
||||
font-weight: 500;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.audit-action-tag {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 2px 8px;
|
||||
border-radius: 4px;
|
||||
font-size: 0.75rem;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.audit-action-tag.info { background: rgba(59,130,246,0.15); color: #60a5fa; }
|
||||
.audit-action-tag.success { background: rgba(16,185,129,0.15); color: #10b981; }
|
||||
.audit-action-tag.warning { background: rgba(249,115,22,0.15); color: #f97316; }
|
||||
.audit-action-tag.error, .audit-action-tag.critical { background: rgba(239,68,68,0.15); color: #ef4444; }
|
||||
.audit-action-tag.default { background: var(--bg-surface-hover); color: var(--text-muted); }
|
||||
|
||||
.audit-resource {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 0.75rem;
|
||||
color: var(--text-muted);
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
.audit-row { grid-template-columns: 60px auto auto; }
|
||||
.audit-resource { display: none; }
|
||||
}
|
||||
|
||||
/* ============================================
|
||||
Page Header Block (unified across all pages)
|
||||
============================================ */
|
||||
|
||||
.page-header-block {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
margin-bottom: var(--spacing-xl);
|
||||
flex-wrap: wrap;
|
||||
gap: var(--spacing-md);
|
||||
}
|
||||
|
||||
.page-header-left {}
|
||||
|
||||
.page-header-title {
|
||||
font-size: 1.5rem;
|
||||
font-weight: 700;
|
||||
color: var(--text-primary);
|
||||
margin: 0 0 0.2rem 0;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
.page-header-sub {
|
||||
font-size: 0.8125rem;
|
||||
color: var(--text-muted);
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.page-header-right {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--spacing-sm);
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
/* Breadcrumb */
|
||||
.breadcrumb-nav {
|
||||
font-size: 0.75rem;
|
||||
color: var(--text-muted);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.35rem;
|
||||
margin-bottom: 0.2rem;
|
||||
}
|
||||
|
||||
.breadcrumb-nav a {
|
||||
color: var(--text-muted);
|
||||
text-decoration: none;
|
||||
transition: color var(--transition-fast);
|
||||
}
|
||||
|
||||
.breadcrumb-nav a:hover { color: var(--primary); }
|
||||
.breadcrumb-sep { opacity: 0.4; }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user