Fix/mobile menu resize bug#455
Conversation
|
@pari-dubey1 is attempting to deploy a commit to the komalsony234-1530's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@komalharshita Please review my PRs (#282 , #455 , #458 ). Thank you! |
komalharshita
left a comment
There was a problem hiding this comment.
Thank you for the contribution.
The mobile menu resize fix itself looks reasonable and directly addresses the issue where the mobile navigation remains open after resizing to desktop view.
However, this PR also includes multiple unrelated changes to the recommendation form submission flow, API error handling, and results rendering logic. These modifications are outside the scope of the reported mobile menu resize issue and make the PR much larger than necessary.
In addition, the PR currently has merge conflicts that must be resolved before it can be reviewed for merge.
Please keep this PR focused only on the mobile menu resize fix, remove the unrelated recommendation-system changes, rebase against the latest main branch, and resolve all merge conflicts.
Requested changes.
9a11397 to
c23ee32
Compare
c23ee32 to
6584be5
Compare
i have done the changes. please review the PR. |
|
Looks good....approved for merge! |
Summary [required]
This PR fixes a responsive navigation issue where the mobile hamburger menu remained open when resizing the browser window from mobile view to desktop view. This caused both the mobile and desktop navigation menus to appear simultaneously.
The fix adds a resize listener that automatically closes and resets the mobile navigation state once the viewport crosses the desktop breakpoint, ensuring consistent responsive behaviour across screen sizes.
Additionally, while testing and debugging the issue, several unintended JavaScript syntax and duplicated logic issues in
script.jswere identified and cleaned up to restore proper functionality of the navbar and overall client-side interactions.Related Issue [required]
Closes #285
Type of Change [required]
data/projects.jsonWhat Was Changed [required]
static/js/script.jsstatic/js/script.jsstatic/js/script.jsrenderResults()conditional logicstatic/js/script.jsHow to Test This PR [required]
Clone this branch:
Install dependencies:
Run the app:
Open:
Open browser responsive/mobile mode
Set viewport to mobile width
Open the hamburger menu
Resize the browser window to desktop width
Verify that:
Run tests:
Expected result:
Test Results [required]
Screenrecording
Screen.Recording.2026-05-22.144304.mp4
Self-Review Checklist [required]
feat/,fix/,docs/,data/,style/,test/python tests/test_basic.pyflake8 .locally and there are no errorsprint()orconsole.log()debug statementsNotes for Reviewer
While implementing the responsive navbar fix, some pre-existing duplicated JavaScript blocks and syntax inconsistencies in
script.jswere discovered that prevented the navbar interactions from functioning correctly. These were cleaned up to restore stable client-side behaviour and ensure accurate testing of the assigned issue.