Lucid / lucid2-react /src /components /Analytics.css
Dev-Ryuzakii
Update API base URL and fix addCamera method
fa5a08c
Raw History Blame Contribute Delete
4.54 kB
.analytics {
padding: 20px;
max-width: 1400px;
margin: 0 auto;
}
.metrics-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 20px;
margin-top: 20px;
}
.metric-card {
background: rgba(0, 255, 157, 0.05);
border: 1px solid rgba(0, 255, 157, 0.2);
border-radius: 8px;
padding: 24px;
text-align: center;
transition: all 0.3s ease;
}
.metric-card:hover {
transform: translateY(-2px);
box-shadow: 0 4px 12px rgba(0, 255, 157, 0.2);
}
.metric-card.active {
border-color: #00ff9d;
background: rgba(0, 255, 157, 0.1);
}
.metric-card.inactive {
border-color: #64748b;
background: rgba(100, 116, 139, 0.1);
}
.metric-card.recent {
border-color: #00e0ff;
background: rgba(0, 224, 255, 0.1);
}
.metric-value {
font-size: 2.5rem;
font-weight: 700;
color: #00ff9d;
margin-bottom: 8px;
}
.metric-label {
font-size: 0.875rem;
color: #a1b5d8;
text-transform: uppercase;
letter-spacing: 0.05em;
}
.camera-analytics-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
gap: 16px;
margin-top: 20px;
}
.camera-analytics-card {
background: rgba(255, 255, 255, 0.02);
border: 1px solid rgba(255, 255, 255, 0.1);
border-radius: 8px;
padding: 16px;
}
.camera-header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 12px;
padding-bottom: 12px;
border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.camera-name {
font-weight: 600;
color: #e6f1ff;
}
.camera-status {
font-size: 0.75rem;
padding: 4px 8px;
border-radius: 4px;
text-transform: uppercase;
}
.camera-status.online {
background: rgba(0, 255, 157, 0.2);
color: #00ff9d;
}
.camera-status.offline {
background: rgba(239, 68, 68, 0.2);
color: #ef4444;
}
.camera-metrics {
display: flex;
flex-direction: column;
gap: 8px;
}
.camera-metric {
display: flex;
justify-content: space-between;
color: #a1b5d8;
font-size: 0.875rem;
}
.camera-metric .value {
font-weight: 600;
color: #e6f1ff;
}
.analytics-row {
display: grid;
grid-template-columns: repeat(2, 1fr);
gap: 20px;
margin-top: 20px;
}
.viz-card.half {
margin: 0;
}
.time-metrics, .movement-metrics {
text-align: center;
padding: 20px 0;
}
.time-value, .movement-value {
font-size: 2rem;
font-weight: 700;
color: #00ff9d;
margin-bottom: 8px;
}
.time-label, .movement-label {
color: #a1b5d8;
font-size: 0.875rem;
text-transform: uppercase;
}
.time-detail, .movement-percentage {
color: #64748b;
font-size: 0.75rem;
margin-top: 4px;
}
.quality-overview {
margin-bottom: 20px;
}
.quality-metric {
display: flex;
justify-content: space-between;
align-items: center;
padding: 12px;
background: rgba(0, 255, 157, 0.05);
border-radius: 6px;
}
.quality-label {
color: #a1b5d8;
}
.quality-value {
font-size: 1.5rem;
font-weight: 700;
color: #00ff9d;
}
.quality-distribution {
display: flex;
flex-direction: column;
gap: 12px;
}
.quality-bar-container {
width: 100%;
height: 40px;
background: rgba(255, 255, 255, 0.02);
border-radius: 6px;
overflow: hidden;
}
.quality-bar {
height: 100%;
display: flex;
align-items: center;
padding: 0 12px;
transition: width 0.5s ease;
}
.quality-bar.high {
background: linear-gradient(90deg, #00ff9d, #00cc7d);
}
.quality-bar.medium {
background: linear-gradient(90deg, #fbbf24, #f59e0b);
}
.quality-bar.low {
background: linear-gradient(90deg, #ef4444, #dc2626);
}
.bar-label {
color: #0a0e27;
font-weight: 600;
font-size: 0.875rem;
}
.performance-metrics {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
gap: 16px;
margin-top: 20px;
}
.performance-item {
display: flex;
justify-content: space-between;
align-items: center;
padding: 12px;
background: rgba(255, 255, 255, 0.02);
border-radius: 6px;
border-left: 3px solid #00ff9d;
}
.perf-label {
color: #a1b5d8;
font-size: 0.875rem;
}
.perf-value {
font-weight: 700;
color: #e6f1ff;
font-size: 1.125rem;
}
.analytics-footer {
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 30px;
padding: 20px;
background: rgba(255, 255, 255, 0.02);
border-radius: 8px;
color: #64748b;
font-size: 0.875rem;
}
@media (max-width: 768px) {
.analytics-row {
grid-template-columns: 1fr;
}
.metrics-grid {
grid-template-columns: repeat(2, 1fr);
}
.camera-analytics-grid {
grid-template-columns: 1fr;
}
}