Skip to content

fix(repositories): weight precision, paginated next-page, drop repo-name tooltip#1249

Merged
entrius merged 1 commit into
testfrom
fix/repositories-ui-tweaks
May 19, 2026
Merged

fix(repositories): weight precision, paginated next-page, drop repo-name tooltip#1249
entrius merged 1 commit into
testfrom
fix/repositories-ui-tweaks

Conversation

@anderdc
Copy link
Copy Markdown
Collaborator

@anderdc anderdc commented May 19, 2026

Summary

  • formatWeight helper formats weight/share values up to 5 decimals and trims trailing zeros (so 0.00350 renders as 0.0035, not 0.04). Applied across the repositories table, leaderboard card, search results, watchlist row + bar chart, and the repository-details Stats panel. Tooltips and axis labels that surfaced Weight use it too.
  • Fix useDataTableParams.setFilter so it only clears the page slot when the filter value actually changes. react-router-dom rebuilds setSearchParams on every URL change; that propagated through useCallback deps and re-fired DebouncedSearchInput's effect, which called setFilter('search', '') and wiped the page param immediately after next-page was clicked. Most visible in cards view with rows=12, but also caused deep links like ?page=N to reset on load.
  • Remove the hover tooltip on the repository-name cell in the repositories table.

Test plan

  • Repositories cards view, rows=12: click "next page" → URL updates to ?page=1 and rows "13–15 of 15" render (verified via Playwright against local dev server).
  • Deep-link /repositories?page=1 keeps you on page 1.
  • Typing in the repositories search still clears page (filter value actually changed).
  • npx tsc -b and eslint clean.
  • Eyeball weight column in cards/list views and on the watchlist for the expected display.
  • Confirm repo-name cell no longer shows a tooltip on hover.

… reset, drop repo-name tooltip

- formatWeight helper rounds weights to up to 5 decimals and trims trailing
  zeros, replacing the toFixed(2) calls that were turning small shares like
  0.0035 into "0.04" across the repositories table, leaderboard cards,
  repository details, search results, and watchlist views.
- setFilter in useDataTableParams now only clears the page slot when the
  filter value actually changes. react-router rebuilds setSearchParams on
  every URL update, which propagated through useCallback deps and caused
  DebouncedSearchInput's effect to re-emit '', wiping the page param
  immediately after next-page was clicked (most visible at rows=12).
- Remove the hover tooltip on the repository-name cell in the repositories
  table.
@entrius entrius merged commit 0843ab1 into test May 19, 2026
2 checks passed
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