Skip to content

fix(frontend): resolve TypeScript build errors and type mismatches - #566

Open
piyushrajpandit wants to merge 1 commit into
AOSSIE-Org:mainfrom
piyushrajpandit:fix/frontend-build-typescript-errors
Open

piyushrajpandit wants to merge 1 commit into
AOSSIE-Org:mainfrom
piyushrajpandit:fix/frontend-build-typescript-errors

Conversation

@piyushrajpandit

@piyushrajpandit piyushrajpandit commented Sep 18, 2026

Copy link
Copy Markdown

Resolves build failures when running npm run build in the frontend directory.

Fixes

  • Updated MatchmakingPoolResponse type reference in teamDebateService.ts.
  • Changed gameResult.points default state from boolean false to number 0 in Game.tsx.
  • Added liveTranscript?: string prop to SpeechTranscriptsProps interface.
  • Resolved currentUserIdRef type assignment in TeamDebateRoom.tsx.
  • Removed unused imports across frontend components.

Tested locally with npm run build (0 errors).

@coderabbitai

coderabbitai Bot commented Sep 18, 2026

Copy link
Copy Markdown

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: aa05128e-0b95-4745-811a-2fa6e94896d4

📥 Commits

Reviewing files that changed from the base of the PR and between 9f90f9b and 37ecbe5.

⛔ Files ignored due to path filters (2)
  • frontend/package-lock.json is excluded by !**/package-lock.json
  • frontend/tsconfig.app.tsbuildinfo is excluded by !**/*.tsbuildinfo
📒 Files selected for processing (7)
  • frontend/src/Pages/Game.tsx
  • frontend/src/Pages/Profile.tsx
  • frontend/src/Pages/TeamDebateRoom.tsx
  • frontend/src/components/CommentTree.tsx
  • frontend/src/components/Footer.tsx
  • frontend/src/components/SpeechTranscripts.tsx
  • frontend/src/services/teamDebateService.ts
💤 Files with no reviewable changes (1)
  • frontend/src/components/Footer.tsx

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The PR corrects frontend state initialization and ref synchronization, adds avatar fallback handling, simplifies comment submission refreshes, adds an optional transcript property, corrects a matchmaking response type, and removes unused code.

Changes

Frontend corrections

Layer / File(s) Summary
Runtime state and avatar handling
frontend/src/Pages/Game.tsx, frontend/src/Pages/Profile.tsx, frontend/src/Pages/TeamDebateRoom.tsx
Game initializes points as 0 and removes unused WebSocket-related code. Profile adds avatar fallback handling. TeamDebateRoom updates refs inside an effect and removes an unused phase variable.
Comment submission refresh
frontend/src/components/CommentTree.tsx
CommentTree removes unused atom bindings and uses fetchComments() after the submission response is consumed.
Frontend contract and cleanup
frontend/src/components/SpeechTranscripts.tsx, frontend/src/services/teamDebateService.ts, frontend/src/components/Footer.tsx
SpeechTranscriptsProps accepts an optional liveTranscript. getMatchmakingPool uses TeamMatchmakingPoolResponse. Footer removes an unused React import.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to 37ecb

The reviewed frontend changes show no confirmed user-facing or production risk and are mergeable with normal checks.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 6…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main changes: frontend TypeScript build errors and type mismatches were fixed across several components and services.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gitcordapp

gitcordapp Bot commented Sep 18, 2026

Copy link
Copy Markdown

Link your account with Gitcord

Thanks for opening this PR, @piyushrajpandit!

To receive Discord notifications and contributor tracking for this organization:

  1. Join Discord: https://discord.gg/hjUhu33uAn
  2. In Discord, run /link piyushrajpandit
  3. Paste the verification code into your GitHub bio (or a public gist)
  4. Click Verify in Discord (or run /verify-link piyushrajpandit)

Once linked, Gitcord can notify you about reviews, merges, and more.

Posted by Gitcord

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.

1 participant