Skip to content

[Bugfix:TAGrading] Fix header overlap#12793

Merged
bmcutler merged 7 commits into
Submitty:mainfrom
GarvitKhandelwal31:fix-12763
Jun 1, 2026
Merged

[Bugfix:TAGrading] Fix header overlap#12793
bmcutler merged 7 commits into
Submitty:mainfrom
GarvitKhandelwal31:fix-12763

Conversation

@GarvitKhandelwal31

Copy link
Copy Markdown
Contributor

Why is this Change Important & Necessary?

Solves #12763
#12766 changes were reverted by the PR #12784 due to a bug identified in the PR #12779
In PR #12779 in mobile view seeing the PDF is very difficult due to this PDF header overlap.
Screen recording of that-

577301720-83a6717d-95f9-4204-8f56-2355431a573c.mp4

What is the New Behavior?

This PR includes all the changes from #12766 while excluding the unnecessary portion identified in #12779. Also it fixes the poor PDF readability in mobile view.

Screen.Recording.2026-04-17.021938.mp4

What steps should a reviewer take to reproduce or test the bug or new feature?

  1. Open TA Grading for a gradeable with PDF submissions.
  2. Open a PDF in the Submissions and Results Browser.
  3. Verify the top file header remains usable while scrolling the PDF content.
  4. Resize browser to narrow/mobile width.
  5. Confirm horizontal overflow is not locking the view and PDF remains scrollable/usable.
  6. Use page navigation/jump behavior and confirm the expected page scroll target is reached.

Automated Testing & Documentation

No new automated tests were added in this PR (UI/layout and scroll behavior adjustment).

Other information

Breaking change: No.
Migrations required: No.
Security concerns: None identified.

Copilot AI review requested due to automatic review settings April 16, 2026 21:13
@github-project-automation github-project-automation Bot moved this to Seeking Reviewer in Submitty Development Apr 16, 2026
@automateprojectmangement automateprojectmangement Bot moved this from Seeking Reviewer to In Review in Submitty Development Apr 16, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Restores the intended TA Grading inline PDF header behavior (no overlap with page 1) while improving usability on narrow/mobile widths by adjusting the file-view layout and scrolling behavior.

Changes:

  • Updates the file-view header styling to be sticky/in-flow and makes the file content area independently scrollable.
  • Adjusts “scroll to page” logic in TA grading and the embedded PDF renderer to account for the new layout.
  • Adds mobile-specific CSS to reduce horizontal overflow issues and allow header rows to wrap.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
site/ts/ta-grading-rubric.ts Updates rubric-driven page navigation scroll logic for PDFs.
site/public/js/pdf/PDFAnnotateEmbedded.js Updates initial PDF page scroll behavior after render.
site/public/css/electronic.css Changes file-view layout: sticky header, scrollable content, and mobile overflow/wrapping tweaks.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread site/public/js/pdf/PDFAnnotateEmbedded.js Outdated
Comment thread site/public/css/electronic.css
Comment thread site/ts/ta-grading-rubric.ts Outdated

@Rkoester47 Rkoester47 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I tested the changes made on this PR and confirm that they work as described. I tested a TA grading gradeable with a PDF. and the info banner above did not cover up the PDF at any point. I made sure to resize my browser window to mobile dimensions, then zoom and scroll on the PDF. The image was not obstructed at any point. However, some tests are failing and they should be addressed before merging.

@github-project-automation github-project-automation Bot moved this from In Review to Awaiting Maintainer Review in Submitty Development Apr 30, 2026
@codecov

codecov Bot commented Apr 30, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 21.67%. Comparing base (4ca4e71) to head (24a5e12).

Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##               main   #12793      +/-   ##
============================================
- Coverage     21.67%   21.67%   -0.01%     
  Complexity     9802     9802              
============================================
  Files           268      268              
  Lines         36724    36725       +1     
  Branches        489      490       +1     
============================================
  Hits           7960     7960              
  Misses        28279    28279              
- Partials        485      486       +1     
Flag Coverage Δ
autograder 21.32% <ø> (ø)
js 2.02% <0.00%> (-0.01%) ⬇️
migrator 100.00% <ø> (ø)
php 20.73% <ø> (ø)
python_submitty_utils 80.08% <ø> (ø)
submitty_daemon_jobs 91.13% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bmcutler

bmcutler commented May 1, 2026

Copy link
Copy Markdown
Member

@GarvitKhandelwal31
Can you please take a look at the failing tests and try to address them?

@GarvitKhandelwal31 GarvitKhandelwal31 changed the title [Bugfix:TAGrading] Fix header overlap with changes for mobile [Bugfix:TAGrading] Fix header overlap May 1, 2026
@bmcutler
bmcutler merged commit 0adc703 into Submitty:main Jun 1, 2026
22 of 25 checks passed
@github-project-automation github-project-automation Bot moved this from Awaiting Maintainer Review to Done in Submitty Development Jun 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants