Skip to content

refactor: remove orphan files and slim FileExplorer to live helpers#977

Merged
anderdc merged 6 commits intoentrius:testfrom
cleanjunc:refactor/remove-orphan-files
May 9, 2026
Merged

refactor: remove orphan files and slim FileExplorer to live helpers#977
anderdc merged 6 commits intoentrius:testfrom
cleanjunc:refactor/remove-orphan-files

Conversation

@cleanjunc
Copy link
Copy Markdown
Contributor

Summary

Drops four orphan files that were exported but never imported by any consumer, plus the dead default export of FileExplorer:

  • src/pages/DiscoveriesPage.tsx (the /discoveries route is already a redirect, so the page never renders)
  • src/components/miners/MinerComparisonRadar.tsx
  • src/components/leaderboard/LeaderboardTableSkeleton.tsx
  • src/components/common/SearchInput.tsx

buildFileTree and the FileNode type from FileExplorer.tsx are still used by RepositoryCodeBrowser, so they move to a focused fileTree.ts utility module and the lone import is updated. Two small redundancies inside the helper were also collapsed: a duplicated comparator and a recursive resort that produced the same ordering the initial sort already guarantees.

Net effect: roughly 470 lines drop out of the bundle, directories stop advertising features that no longer work, and grep on these component names stops returning orphans.

Related Issues

Closes #976

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation
  • Other (describe below)

Screenshots

Not applicable. No UI or visual changes.

Checklist

  • New components are modularized/separated where sensible
  • Uses predefined theme (e.g. no hardcoded colors)
  • Responsive/mobile checked
  • Tested against the test API
  • npm run format and npm run lint:fix have been run
  • npm run build passes
  • Screenshots included for any UI/visual changes

@cleanjunc
Copy link
Copy Markdown
Contributor Author

@anderdc Could you please review this PR? Thanks!

@xiao-xiao-mao xiao-xiao-mao Bot added the refactor Code restructuring without behavior change label May 7, 2026
@anderdc
Copy link
Copy Markdown
Collaborator

anderdc commented May 9, 2026

Fix conflicts.

@cleanjunc
Copy link
Copy Markdown
Contributor Author

Hi @anderdc
I've fixed the conflicts. Could you please review again?
Thank you!

@cleanjunc cleanjunc force-pushed the refactor/remove-orphan-files branch from 6e5a33c to 4b54300 Compare May 9, 2026 19:08
@anderdc anderdc merged commit 051f963 into entrius:test May 9, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor Code restructuring without behavior change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Several page and component files are exported but never imported anywhere

2 participants