:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
fix(today): show a working spinner on running sidebar sessions (#109840)
Shy Alter4fa6bbd98aa5
diff --git a/frontend/src/layout/today/TodaySessionStatusDot.tsx b/frontend/src/layout/today/TodaySessionStatusDot.tsxindex 7abf4c458760..7d92f87b6a19 100644--- a/frontend/src/layout/today/TodaySessionStatusDot.tsx+++ b/frontend/src/layout/today/TodaySessionStatusDot.tsx@@ -1,5 +1,4 @@-import { IconSpinner } from '@posthog/icons'-import { Tooltip, TooltipContent, TooltipTrigger, cn } from '@posthog/quill'+import { Spinner, Tooltip, TooltipContent, TooltipTrigger, cn } from '@posthog/quill'import { TodaySessionDot } from './todaySessionDot'@@ -17,8 +16,12 @@ export function TodaySessionStatusDot({ dot }: { dot: TodaySessionDot }): JSX.Elrender={<span className="relative flex size-2 shrink-0 items-center justify-center" />}>{dot.mark === 'spinner' ? (- <span role="img" aria-label={dot.label} className="relative size-2">- <IconSpinner className="absolute -inset-0.5 size-3 text-muted-foreground motion-safe:animate-spin" />+ <span className="relative size-2">+ <Spinner+ role="img"+ aria-label={dot.label}+ className="absolute -inset-0.5 size-3 text-muted-foreground motion-reduce:animate-none"+ /></span>) : (<spandiff --git a/frontend/src/layout/today/todaySessionDot.test.ts b/frontend/src/layout/today/todaySessionDot.test.tsindex 381d9f7d1579..b28a39f30795 100644--- a/frontend/src/layout/today/todaySessionDot.test.ts+++ b/frontend/src/layout/today/todaySessionDot.test.ts@@ -6,7 +6,7 @@ describe('todaySessionDot', () => {['a queued cloud run', 'queued', 'cloud', false, { mark: 'spinner', label: 'Queued' }],['a cloud run that has not started', 'not_started', 'cloud', true, { mark: 'spinner', label: 'Starting' }],['a queued local run', 'queued', 'local', false, { mark: 'hollow', label: 'Queued' }],- ['a running session', 'in_progress', 'cloud', false, { mark: 'solid', label: 'Running' }],+ ['a running session, even when unread', 'in_progress', 'cloud', true, { mark: 'spinner', label: 'Working' }],['an unread finished session', 'completed', 'cloud', true, { mark: 'solid', label: 'Unread' }],['a finished session', 'completed', 'cloud', false, { mark: 'hollow', label: 'Completed' }],['a stopped session', 'cancelled', 'cloud', false, { mark: 'hollow', faint: true, label: 'Stopped' }],diff --git a/frontend/src/layout/today/todaySessionDot.ts b/frontend/src/layout/today/todaySessionDot.tsindex 3bf038948b82..4009e4a5c157 100644--- a/frontend/src/layout/today/todaySessionDot.ts+++ b/frontend/src/layout/today/todaySessionDot.ts@@ -1,7 +1,7 @@import { TodayWorkItem } from './todayWorkItems'export interface TodaySessionDot {- /** `hollow` is settled, `solid` wants a look, `failed` is red, `spinner` is still starting. */+ /** `hollow` is settled, `solid` wants a look, `failed` is red, `spinner` is starting or working. */mark: 'hollow' | 'solid' | 'failed' | 'spinner'/** Barely there, for a run somebody stopped. */faint: boolean@@ -28,7 +28,7 @@ export function todaySessionDot(return { mark: 'spinner', faint: false, label: startingLabel }}if (status === 'in_progress') {- return { mark: 'solid', faint: false, label: 'Running' }+ return { mark: 'spinner', faint: false, label: 'Working' }}if (unread) {return { mark: 'solid', faint: false, label: 'Unread' }