feat: live preview toggle, FPS indicator, live counting by object
- Toggle ON/OFF switch to disable preview (faster processing) - FPS badge showing rolling average processing speed - Live Loading/Unloading/Net counts updated in real-time - Pipeline callback pushes stats every 10 frames - Frontend polls and updates display every 2s - 62/62 tests pass
This commit is contained in:
1 parent
b6379e14c9
commit
09a8829575
7 files changed
+383
-1
No files matched your search
@@ -660,6 +660,99 @@ main {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.live-preview-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-3);
|
||||
margin-bottom: var(--space-3);
|
||||
}
|
||||
|
||||
.live-preview-header .section-title {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
|
||||
.live-fps {
|
||||
font-size: var(--text-xs);
|
||||
font-weight: var(--font-semibold);
|
||||
color: var(--color-primary);
|
||||
background: var(--color-primary-50, #f0fdfa);
|
||||
padding: 2px 8px;
|
||||
border-radius: var(--radius-sm);
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.toggle-label {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-2);
|
||||
cursor: pointer;
|
||||
font-size: var(--text-sm);
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
.toggle-label input[type="checkbox"] {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.toggle-switch {
|
||||
width: 36px;
|
||||
height: 20px;
|
||||
background: var(--color-neutral-300);
|
||||
border-radius: 10px;
|
||||
position: relative;
|
||||
transition: background var(--transition-fast);
|
||||
}
|
||||
|
||||
.toggle-switch::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
background: white;
|
||||
border-radius: 50%;
|
||||
top: 2px;
|
||||
left: 2px;
|
||||
transition: transform var(--transition-fast);
|
||||
}
|
||||
|
||||
.toggle-label input:checked + .toggle-switch {
|
||||
background: var(--color-primary);
|
||||
}
|
||||
|
||||
.toggle-label input:checked + .toggle-switch::after {
|
||||
transform: translateX(16px);
|
||||
}
|
||||
|
||||
.toggle-text {
|
||||
font-weight: var(--font-medium);
|
||||
color: var(--color-neutral-600);
|
||||
}
|
||||
|
||||
.live-counts {
|
||||
display: flex;
|
||||
gap: var(--space-6);
|
||||
padding: var(--space-3) 0;
|
||||
border-top: 1px solid var(--color-neutral-100);
|
||||
margin-top: var(--space-3);
|
||||
}
|
||||
|
||||
.live-count-item {
|
||||
text-align: center;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.live-count-label {
|
||||
font-size: var(--text-xs);
|
||||
color: var(--color-neutral-500);
|
||||
display: block;
|
||||
margin-bottom: var(--space-1);
|
||||
}
|
||||
|
||||
.live-count-value {
|
||||
font-size: var(--text-2xl);
|
||||
font-weight: var(--font-bold);
|
||||
}
|
||||
|
||||
.preview-placeholder {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
|
||||
Reference in new issue
Block a user