Skip to content

feat(logs): add Slack-like scroll UX to service, deployment and cluster logs#2592

Open
acarranoqovery wants to merge 3 commits intonew-navigationfrom
feat/logs-slack-scroll-ux-v2
Open

feat(logs): add Slack-like scroll UX to service, deployment and cluster logs#2592
acarranoqovery wants to merge 3 commits intonew-navigationfrom
feat/logs-slack-scroll-ux-v2

Conversation

@acarranoqovery
Copy link
Copy Markdown
Contributor

@acarranoqovery acarranoqovery commented Apr 13, 2026

Summary

  • When the user scrolls up in live logs (service, deployment, cluster), the view sticks to the current position instead of following new incoming lines
  • A "Jump to latest log" button appears at the bottom with a badge showing the count of new log lines received while scrolled away
  • Scrolling back to the bottom automatically resumes live streaming and dismisses the button
  • Scrolling up now requires crossing an 80px threshold before pausing, preventing accidental triggers from small scroll gestures
  • Fixed: deployment logs were not rendering new lines while scrolled up — incoming message chunks were blocked from flushing to the DOM until the user scrolled back down, causing a visible pop of content on resume
  • Renamed internal state for clarity: pauseLogsisScrollPaused, newLogsAvailable (boolean) → bufferedLogsCount (number)

Screenshots / Recordings

N/A

Testing

  • Changes tested locally in the relevant Console's pages and Storybooks
  • yarn test or yarn test -u (if you need to regenerate snapshots)
  • yarn format
  • yarn lint

PR Checklist

  • I followed naming, styling, and TypeScript rules (see .cursor/rules)
  • I performed a self-review (diff inspected, dead code removed)
  • I titled the PR using Conventional Commits with a scope when possible (e.g. feat(service): add new Terraform service) - required for semantic-release
  • I only kept necessary comments, written in English (watch for useless AI comments)
  • I involved a designer to validate UI changes if I am not a designer
  • I covered new business logic with tests (unit)
  • I confirmed CI is green (Codecov red can be accepted)
  • I reviewed and executed locally any AI-assisted code

…ter logs

- When the user scrolls up, the view sticks to the current position
- A "Jump to latest log" button appears at the bottom with a badge showing the count of new log lines received while scrolled away
- Scrolling back to the bottom automatically resumes live streaming
- Pausing on scroll now requires a 80px threshold to avoid accidental triggers
- Fixed deployment logs not rendering new lines while scrolled up (chunks were blocked from flushing when paused)
- Renamed internal state: pauseLogs → isScrollPaused, newLogsAvailable → bufferedLogsCount for clarity
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 13, 2026

Codecov Report

❌ Patch coverage is 14.89362% with 80 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (new-navigation@89901b8). Learn more about missing BASE report.

Files with missing lines Patch % Lines
.../lib/list-deployment-logs/list-deployment-logs.tsx 18.18% 17 Missing and 1 partial ⚠️
...b/hooks/use-deployment-logs/use-deployment-logs.ts 0.00% 17 Missing ⚠️
...re/src/lib/list-service-logs/list-service-logs.tsx 11.76% 15 Missing ⚠️
...oks/use-service-live-logs/use-service-live-logs.ts 0.00% 14 Missing ⚠️
...uster-logs/cluster-logs-list/cluster-logs-list.tsx 38.09% 10 Missing and 3 partials ⚠️
.../lib/show-new-logs-button/show-new-logs-button.tsx 0.00% 1 Missing and 2 partials ⚠️
Additional details and impacted files
@@                Coverage Diff                @@
##             new-navigation    #2592   +/-   ##
=================================================
  Coverage                  ?   45.36%           
=================================================
  Files                     ?      702           
  Lines                     ?    17014           
  Branches                  ?     5046           
=================================================
  Hits                      ?     7718           
  Misses                    ?     7899           
  Partials                  ?     1397           
Flag Coverage Δ
unittests 45.36% <14.89%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@TheoGrandin74
Copy link
Copy Markdown
Contributor

@acarranoqovery Looks good to me UX-wise, much better behavior than today. UI wise, I think I would probably remove the icon as it's a bit redundant and visually a bit clunky when we have both the numbers of new logs + the icon (too visually noisy imo).
image

If we want to keep the icon, then just switch it to a arrow-bottom, currently the icon use is the one that is traditionally used for "download" actions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants