// Loading indicator — three pulsing dots above an optional label. A // lightweight replacement for empty-color placeholders during heavy // loads (search, large grids, the playlist manager, etc.). import { Theme } from "../foundation/semantic-colors.slint"; component Dot inherits Rectangle { in property delay; // 0..1 phase offset width: 8px; height: 8px; border-radius: 4px; background: Theme.text-secondary; property phase: Math.mod((animation-tick() / 1ms) / 900.0 + root.delay, 1.0); property tri: 1.0 - Math.abs(root.phase - 0.5) * 2.0; opacity: 0.25 + 0.55 * tri; } export component LoadingDots inherits Rectangle { in property label; VerticalLayout { alignment: center; spacing: 12px; HorizontalLayout { alignment: center; spacing: 8px; Dot { delay: 0.0; } Dot { delay: 0.18; } Dot { delay: 0.36; } } if root.label != "": Text { text: root.label; color: Theme.text-muted; font-size: 13px; horizontal-alignment: center; } } }