Skip to content

feat(dashboard): client-side list sort and pagination (#418) - #432

Merged
unjica merged 9 commits into
developfrom
feature/418-client-list-sort
Jul 14, 2026
Merged

unjica merged 9 commits into
developfrom
feature/418-client-list-sort

Conversation

@unjica

@unjica unjica commented Jul 14, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Add SWR-based client list fetching so sort and pagination on sessions, errors, and events refetch table rows only without a full page navigation.
  • Keep summary metrics and analytics charts server-rendered on first paint; URL remains the source of truth via history.replaceState.
  • Split list toolbars into server filter forms plus a dedicated client sort row with loading overlay on the table.

Test plan

  • pnpm lint && pnpm test && pnpm build
  • On sessions/errors/events: change sort + order → table updates, URL updates, summary/charts unchanged
  • Paginate via controls → table updates without full reload
  • Apply filters/time range → full server navigation still works
  • Copy URL after sort/page change → reload restores same list state

Closes #418

Made with Cursor

Sort and page changes on sessions, errors, and events refetch table rows via SWR while keeping summary charts server-rendered and the URL as source of truth.

Co-authored-by: Cursor <[email protected]>
unjica and others added 2 commits July 14, 2026 20:19
Route client list fetches through a same-origin telemetry proxy so httpOnly session cookies authenticate, sync list state on browser back/forward, skip mount revalidation flash, and restore sessions filter submit.

Co-authored-by: Cursor <[email protected]>
Include hidden sort/order fields in client-mode filter forms and show ErrorState when SWR refetches fail instead of stale rows.

Co-authored-by: Cursor <[email protected]>
Client list refetches now stamp a fresh metricsUntil anchor for unselected time ranges, and ErrorState stays visible during SWR retries instead of showing stale rows.

Co-authored-by: Cursor <[email protected]>
Restrict the client API proxy to a single safe path segment and preserve internal list params like metricsUntil and view when navigating with the browser back button.

Co-authored-by: Cursor <[email protected]>
Reset listParams when initialListParams changes from a filter or time-range navigation, and base patchListQuery on the fresh server params instead of stale client state.

Co-authored-by: Cursor <[email protected]>
…nges

Merge live list params into toolbar navigation so pushState sort/page state
survives pagination and time-range updates after client-side list changes.

Co-authored-by: Cursor <[email protected]>
Preserve sessions chart page on bucket changes, skip duplicate history entries when sort is unchanged, and omit API-only params from client-side URL updates.

Co-authored-by: Cursor <[email protected]>

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit d5ad0d1. Configure here.

Use liveUrlParams for event-name drill-down links so API-only keys stay
out of shareable URLs, and show a refresh banner instead of replacing the
table when SWR refetch fails with cached data.

Co-authored-by: Cursor <[email protected]>
@unjica
unjica merged commit e1d4710 into develop Jul 14, 2026
5 of 6 checks passed
@unjica
unjica deleted the feature/418-client-list-sort branch July 14, 2026 19:16
@unjica unjica added this to the v1.9.x — Platform releases milestone Jul 14, 2026
@unjica unjica mentioned this pull request Jul 14, 2026
1 of 6 tasks
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.

Dashboard: client-side list table sort (SWR/React Query)

1 participant