Skip to content

Conversation

@petkybenedek
Copy link
Contributor

refs: MBL-19382
builds: Student
affects: Student
release note: none

Test plan

Submit a Student Annotation assignment. The toolbar buttons should not be misaligned and should appear correctly.

Screenshots

BeforeAfter

Checklist

  • Follow-up e2e test ticket created
  • A11y checked
  • Tested on phone
  • Tested on tablet
  • Tested in dark mode
  • Tested in light mode
  • Approve from product

refs: MBL-19382
builds: Student
affects: Student
release note: none
Copy link

@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.

Review Summary

This PR simplifies the toolbar button implementation by removing a workaround for SwiftUI font weight overriding and adopts the toolbarItemForegroundStyle custom view modifier pattern that's already being used elsewhere in the codebase.

Positive Feedback ✅

  • Good refactoring: Removes the hacky workaround with the hidden image (Image.assignmentLine.frame(width: 0, height: 0).clipped()) which was only there to prevent nav bar font weight override
  • Consistent pattern: Uses toolbarItemForegroundStyle, which is the established pattern in the codebase (seen in SpeedGraderScreen.swift, GradeListScreen.swift, etc.)
  • Cleaner code: Simplifies the doneButton implementation by removing the unnecessary HStack wrapper
  • Better SwiftUI practices: Using the trailing closure syntax for buttons is cleaner and more idiomatic
  • iOS 26 ready: The custom toolbarItemForegroundStyle modifier handles iOS 26 compatibility gracefully

Issues Found 🔧

  • Extra blank line at Student/Student/Submissions/StudentAnnotationSubmission/StudentAnnotationSubmissionView.swift:60 should be removed

The change is well-aligned with the project's goals of removing SwiftUI workarounds and maintaining code quality.

@petkybenedek petkybenedek self-assigned this Jan 26, 2026
@inst-danger
Copy link
Contributor

inst-danger commented Jan 26, 2026

Warnings
⚠️ This pull request will not generate a release note.

Affected Apps: Student

Builds: Student

MBL-19382

Coverage New % Master % Delta
Canvas iOS 91.42% 81.06% 10.35%

Generated by 🚫 dangerJS against 096ae34

@inst-danger
Copy link
Contributor

inst-danger commented Jan 26, 2026

Builds

Commit: Remove newline (096ae34)
Build Number: 1211
Built At: Jan 26 17:27 CET (01/26 09:27 AM MST)

Student

Copy link
Contributor

@suhaibabsi-inst suhaibabsi-inst left a comment

Choose a reason for hiding this comment

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

QA +1

Tested on iPhone 16, iOS 26

Copy link
Contributor

@rh12 rh12 left a comment

Choose a reason for hiding this comment

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

QA + 1

Copy link
Collaborator

@vargaat vargaat left a comment

Choose a reason for hiding this comment

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

QA+1

@vargaat vargaat merged commit 08fa3d2 into master Jan 27, 2026
9 checks passed
@vargaat vargaat deleted the bugfix/MBL-19382-Student-annotation-toolbar branch January 27, 2026 09:49
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.

6 participants