Skip to content

refactor: Move icons, remove unused files#7171

Merged
kyle-ssg merged 9 commits intomainfrom
refactor/delete-unused-files
Apr 8, 2026
Merged

refactor: Move icons, remove unused files#7171
kyle-ssg merged 9 commits intomainfrom
refactor/delete-unused-files

Conversation

@kyle-ssg
Copy link
Copy Markdown
Member

@kyle-ssg kyle-ssg commented Apr 8, 2026

Thanks for submitting a PR! Please check the boxes below:

  • I have read the Contributing Guide.
  • I have filled in the "Changes" section below.
  • I have filled in the "How did you test this code" section below.

Changes

Remove 36 unused frontend files identified via knip static analysis, verified with manual grep cross-referencing.

Move icons to icons folder.

Dead pages (3): ComingSoonPage, ConfirmEmailPage, HomeAside — zero references anywhere in the codebase.

Dead components (11): AsideProjectButton, AsideTitleLink, Collapsible, Confidence, ConversionEventSelect, ExistingChangeRequestAlert,
HistoryIcon, MetadataTitle, ProjectSelect, RebrandBanner, Resources — no imports found.

Unused SVG icons (14): ArrowUpIcon, CaretDownIcon, CaretRightIcon, DocumentationIcon, EnvironmentSettingsIcon, FeaturesIcon,
LogoutIcon, OrgSettingsIcon, PlayIcon, PlusIcon, ProjectSettingsIcon, SparklesIcon, UpgradeIcon, UserSettingsIcon — none imported
anywhere.

Unused hooks/services (4): useMediaQuery, useConversionEvent, mockAdminDashboardData, useSetupCustomWidget — zero consumers.

Dead base files (3): format-base.js, utils-base.js, base/forms/Tabs.js — zero imports.

Duplicate TS migration leftover (1): CreateWebhook.js — the .tsx version is what webpack resolves (.tsx comes before .js in resolve
extensions).

Unused exports - to clear up what's used vs not I've removed any unused exports e.g. types / variables that are just used within that file.

How did you test this code?

  1. Ran knip to identify unused files via static analysis of the import graph.
  2. Manually verified every candidate with ide across all files to confirm zero references.
  3. Ran npm run typecheck — error count went from 771 → 747 (24 fewer, all from deleted files that previously had errors). No new errors introduced.

ps: Apologies in advance for monster PR

@kyle-ssg kyle-ssg requested a review from a team as a code owner April 8, 2026 10:17
@kyle-ssg kyle-ssg requested review from Zaimwa9 and removed request for a team April 8, 2026 10:17
Copy link
Copy Markdown

@claude claude bot left a comment

Choose a reason for hiding this comment

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

⚠️ Code review skipped — your organization's overage spend limit has been reached.

Code review is billed via overage credits. To resume reviews, an organization admin can raise the monthly limit at claude.ai/admin-settings/claude-code.

Once credits are available, reopen this pull request to trigger a review.

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 8, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
flagsmith-frontend-preview Ready Ready Preview, Comment Apr 8, 2026 3:26pm
flagsmith-frontend-staging Ready Ready Preview, Comment Apr 8, 2026 3:26pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
docs Ignored Ignored Preview Apr 8, 2026 3:26pm

Request Review

@github-actions github-actions bot added front-end Issue related to the React Front End Dashboard refactor labels Apr 8, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

Docker builds report

Image Build Status Security report
ghcr.io/flagsmith/flagsmith-api-test:pr-7171 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-e2e:pr-7171 Finished ✅ Skipped
ghcr.io/flagsmith/flagsmith-api:pr-7171 Finished ✅ Results
ghcr.io/flagsmith/flagsmith:pr-7171 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-private-cloud:pr-7171 Finished ✅ Results
ghcr.io/flagsmith/flagsmith-frontend:pr-7171 Finished ✅ Results

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 8, 2026

Playwright Test Results (oss - depot-ubuntu-latest-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  38.4 seconds
commit  c196ade
info  🔄 Run: #15868 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  38.2 seconds
commit  64ea988
info  🔄 Run: #15869 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-arm-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  1.5 seconds
commit  64ea988
info  🔄 Run: #15869 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

passed  17 passed

Details

stats  17 tests across 14 suites
duration  49.9 seconds
commit  64ea988
info  🔄 Run: #15869 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

failed  2 failed

Details

stats  2 tests across 2 suites
duration  24.8 seconds
commit  c196ade
info  📦 Artifacts: View test results and HTML report
🔄 Run: #15868 (attempt 1)

Failed tests

firefox › tests/change-request-test.pw.ts › Change Request Tests › Change requests can be created, approved, and published with 4-eyes approval @enterprise
firefox › tests/roles-test.pw.ts › Roles Tests › Roles can be created with project and environment permissions @enterprise

### Playwright Test Results (private-cloud - depot-ubuntu-latest-arm-16)

passed  17 passed

Details

stats  17 tests across 14 suites
duration  1 minute
commit  64ea988
info  🔄 Run: #15869 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-16)

failed  1 failed

Details

stats  1 test across 1 suite
duration  47.5 seconds
commit  8d89630
info  📦 Artifacts: View test results and HTML report
🔄 Run: #15871 (attempt 1)

Failed tests

firefox › tests/segment-test.pw.ts › Segment test 1 - Create, update, and manage segments with multivariate flags @oss

### Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

failed  1 failed

Details

stats  1 test across 1 suite
duration  47.5 seconds
commit  8d89630
info  📦 Artifacts: View test results and HTML report
🔄 Run: #15871 (attempt 1)

Failed tests

firefox › tests/segment-test.pw.ts › Segment test 1 - Create, update, and manage segments with multivariate flags @oss

### Playwright Test Results (oss - depot-ubuntu-latest-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  46.2 seconds
commit  cc7bace
info  🔄 Run: #15874 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-arm-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  12.1 seconds
commit  cc7bace
info  🔄 Run: #15874 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-arm-16)

passed  17 passed

Details

stats  17 tests across 14 suites
duration  56.8 seconds
commit  cc7bace
info  🔄 Run: #15874 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

passed  1 passed

Details

stats  1 test across 1 suite
duration  47.7 seconds
commit  cc7bace
info  🔄 Run: #15874 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  43.1 seconds
commit  4978078
info  🔄 Run: #15892 (attempt 1)

Playwright Test Results (oss - depot-ubuntu-latest-arm-16)

passed  11 passed

Details

stats  11 tests across 8 suites
duration  30 seconds
commit  4978078
info  🔄 Run: #15892 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-arm-16)

passed  2 passed

Details

stats  2 tests across 2 suites
duration  1 minute, 5 seconds
commit  4978078
info  🔄 Run: #15892 (attempt 1)

Playwright Test Results (private-cloud - depot-ubuntu-latest-16)

passed  17 passed

Details

stats  17 tests across 14 suites
duration  58.7 seconds
commit  4978078
info  🔄 Run: #15892 (attempt 1)

@kyle-ssg kyle-ssg marked this pull request as ready for review April 8, 2026 11:33
Zaimwa9
Zaimwa9 previously approved these changes Apr 8, 2026
Copy link
Copy Markdown
Contributor

@talissoncosta talissoncosta left a comment

Choose a reason for hiding this comment

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

LGTM. Good use of knip for the sweep, and the icon reorganisation makes the folder structure cleaner. Monster PR but entirely safe deletions and import path updates, which made it straightforward to review. :smiling

@kyle-ssg kyle-ssg merged commit 589c5d5 into main Apr 8, 2026
30 checks passed
@kyle-ssg kyle-ssg deleted the refactor/delete-unused-files branch April 8, 2026 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

front-end Issue related to the React Front End Dashboard refactor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Review legacy unused frontend files

3 participants