Skip to content

Conversation

@tamaskozmer
Copy link
Contributor

@tamaskozmer tamaskozmer commented Dec 5, 2025

Added Portfolio launch definition support to the navigation drawer for Student and Teacher apps. Portfolio appears when the backend provides the Portfolio launch definition with domain "iad.portfolio.instructure.com".

Changes

  • Added PORTFOLIO_DOMAIN constant to LaunchDefinition model
  • Added portfolio string resource
  • Added Portfolio UI element to navigation drawers in Student and Teacher apps
  • Added Portfolio click handling to launch LTI tool
  • Added Portfolio visibility logic based on launch definitions
  • Student app includes offline state handling

Test plan:

  1. Student app: Open navigation drawer, verify Portfolio appears if launch definition is present
  2. Teacher app: Open navigation drawer, verify Portfolio appears if launch definition is present
  3. Click Portfolio item, verify it launches the LTI tool correctly
  4. Student app: Test in offline mode, verify Portfolio is dimmed
  5. Verify Portfolio is hidden when launch definition is not provided

refs: MBL-19586
affects: Student, Teacher
release note: Added Portfolio to the navigation menu for Student and Teacher apps

Checklist

  • Follow-up e2e test ticket created or not needed
  • Tested in dark mode
  • Tested in light mode
  • Test in landscape mode and/or tablet
  • A11y checked
  • Approve from product

🤖 Generated with Claude Code

Co-Authored-By: Claude [email protected]

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 adds Portfolio navigation drawer integration to both Student and Teacher apps, following the same pattern as existing LTI tools (Studio, Gauge, Mastery, Arc).

Positive Observations

Consistent implementation - The changes follow the exact same pattern as existing LTI tools (Studio, Gauge, Mastery, Arc)
Both apps updated - Student and Teacher apps are updated in parallel with matching functionality
Complete integration - All necessary touchpoints are covered: click handlers, offline state handling, visibility management
Proper UI structure - Layout XML follows existing navigation drawer item patterns
Icon resource added - Vector drawable for the portfolio icon is properly included

Issues Found

  • Region-specific domain (LaunchDefinition.kt:40) - The Portfolio domain uses iad.portfolio.instructure.com which appears region-specific (IAD = US-East), unlike other services. Verify if this should be configurable or if a generic domain should be used instead.
  • Mastery offline handling added (NavigationActivity.kt:779) - This PR incidentally fixes missing offline alpha handling for the Mastery item (in addition to adding Portfolio). This is correct but represents an additional fix beyond the PR's primary goal.

Code Quality

The implementation is clean and follows established patterns. No performance, security, or architectural concerns identified.

Test Coverage

⚠️ No test files were modified in this PR. Consider adding:

  • UI tests for the Portfolio navigation item visibility based on launch definitions
  • Tests for offline state handling of the Portfolio item
  • Tests for the LTI launch flow with Portfolio

Recommendation

The implementation looks solid overall. The main concern is the hardcoded region-specific domain which may cause issues for users in other regions. Please verify this is the intended behavior before merging.

@github-actions
Copy link

github-actions bot commented Dec 5, 2025

🧪 Unit Test Results

✅ 📱 Student App

  • Tests: 1226 total, 0 failed, 0 skipped
  • Duration: 0.000s
  • Success Rate: 100%

✅ 📱 Teacher App

  • Tests: 364 total, 0 failed, 0 skipped
  • Duration: 35.706s
  • Success Rate: 100%

✅ 🌅 Horizon

  • Tests: 449 total, 0 failed, 0 skipped
  • Duration: 27.519s
  • Success Rate: 100%

✅ 📦 Submodules

  • Tests: 2418 total, 0 failed, 0 skipped
  • Duration: 43.800s
  • Success Rate: 100%

📊 Summary

  • Total Tests: 4457
  • Failed: 0
  • Skipped: 0
  • Status: ✅ All tests passed!

Last updated: Fri, 05 Dec 2025 15:12:36 GMT

@tamaskozmer tamaskozmer changed the title [MBL-19586] Add Portfolio to the Navigation menu [MBL-19586][Student][Teacher] Add Portfolio to the Navigation menu Dec 5, 2025
@github-actions
Copy link

github-actions bot commented Dec 5, 2025

📊 Code Coverage Report

✅ Student

  • PR Coverage: 42.77%
  • Master Coverage: 42.77%
  • Delta: +0.00%

✅ Teacher

  • PR Coverage: 25.45%
  • Master Coverage: 25.45%
  • Delta: +0.00%

⚠️ Pandautils

  • PR Coverage: 22.56%
  • Master Coverage: 22.56%
  • Delta: -0.00%

📈 Overall Average

  • PR Coverage: 30.26%
  • Master Coverage: 30.26%
  • Delta: -0.00%

@github-actions
Copy link

github-actions bot commented Dec 5, 2025

Teacher Install Page

@github-actions
Copy link

github-actions bot commented Dec 5, 2025

Student Install Page

Copy link
Collaborator

@hermannakos hermannakos 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
Contributor

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

@tamaskozmer tamaskozmer merged commit 4a640a7 into master Dec 9, 2025
28 of 29 checks passed
@tamaskozmer tamaskozmer deleted the MBL-19586-Add-ePortfolio-to-the-Navigation-menu branch December 9, 2025 16:50
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.

5 participants