Files
Control-Center/frontend/src/app/pages/hub/hub-page.component.scss
rex-bot a946670157
All checks were successful
Dev Build / build-test (pull_request) Successful in 2m4s
CUB-20: Develop agent card component with dynamic status/progress
2026-04-28 08:18:27 -04:00

121 lines
2.4 KiB
SCSS
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
// ============================================================================
// Hub Page — Responsive AgentCard Grid
// Desktop (≥1024px): 2×2 grid
// Mobile (<1024px): single-column stack
// ============================================================================
@use 'tokens' as tokens;
.hub-page {
display: grid;
grid-template-columns: 1fr;
gap: tokens.$cc-card-gap;
padding: tokens.$cc-section-padding;
min-height: 400px;
overflow-x: hidden;
}
// Desktop / kiosk breakpoint — 2-column grid
@media (min-width: tokens.$cc-breakpoint-desktop) {
.hub-page {
grid-template-columns: repeat(2, 1fr);
}
}
// ── Loading state ──
.hub-page__loading {
grid-column: 1 / -1;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 12px;
padding: 48px 24px;
color: var(--cc-on-surface-variant);
}
.hub-page__loading-icon {
font-size: 40px;
width: 40px;
height: 40px;
color: var(--status-active);
animation: spin 1.5s linear infinite;
}
.hub-page__loading-text {
font-size: 16px;
color: var(--cc-on-surface-variant);
margin: 0;
}
@keyframes spin {
from { transform: rotate(0deg); }
to { transform: rotate(360deg); }
}
// ── Empty state ──
.hub-page__empty {
grid-column: 1 / -1;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 8px;
padding: 48px 24px;
text-align: center;
}
.hub-page__empty-icon {
font-size: 48px;
width: 48px;
height: 48px;
color: var(--status-offline);
}
.hub-page__empty-text {
font-size: 18px;
font-weight: 500;
color: var(--cc-on-surface);
margin: 0;
}
.hub-page__empty-hint {
font-size: 14px;
color: var(--cc-on-surface-variant);
margin: 0;
}
// ── Error state ──
.hub-page__error {
grid-column: 1 / -1;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 8px;
padding: 24px;
border: 1px solid var(--status-error);
border-radius: tokens.$cc-card-border-radius;
background-color: var(--status-error-bg);
}
.hub-page__error-icon {
font-size: 32px;
width: 32px;
height: 32px;
color: var(--status-error);
}
.hub-page__error-text {
font-size: 14px;
color: var(--status-error);
margin: 0;
text-align: center;
}
// ── Accessibility: reduced motion ──
@media (prefers-reduced-motion: reduce) {
.hub-page__loading-icon {
animation: none;
}
}