Skip to content

feat: add exams link to header menu#10

Merged
bra-i-am merged 5 commits intomainfrom
vue/PADV-1973
Nov 11, 2025
Merged

feat: add exams link to header menu#10
bra-i-am merged 5 commits intomainfrom
vue/PADV-1973

Conversation

@bra-i-am
Copy link

@bra-i-am bra-i-am commented Oct 20, 2025

This pull request adds support for conditionally displaying an "Exams" dashboard link in the site header, based on the ENABLE_EXAM_DASHBOARD configuration flag.

Feature addition:

  • Added logic in Header.jsx to display an "Exams" link in the navigation menu when config.ENABLE_EXAM_DASHBOARD is true. The link uses the URL from config.EXAM_DASHBOARD_MFE_BASE_URL.
  • Added a new message definition for the "Exams" link in Header.messages.jsx for internationalization support.

How to test

  1. Run a Pearson environment with Tutor or devstack
  2. Ensure you have an MFE cloned to test this header component, and run it npm install to install the dependencies
  3. Then run npm i @edx/frontend-component-header@github:Pearson-Advance/frontend-component-header#vue/PADV-1973 to install this branch in your MFE
  4. Ensure your site configs look like this; in this case, I'm running everything over the default lms.main.localhost:18000 site:
{
    "course_org_filter": [
        "PX"
    ],
    "COURSE_CATALOG_API_URL": "http://discovery.main.localhost:18381/api/v1/",
    "ECOMMERCE_PUBLIC_URL_ROOT": "http://ecommerce.main.localhost:18130/",
    "ECOMMERCE_API_URL": "http://ecommerce.main.localhost:18130/",
    "SESSION_COOKIE_DOMAIN": ".main.localhost",
    "MFE_CONFIG": {
        "LMS_BASE_URL": "http://lms.main.localhost:18000",
        "LOGIN_URL": "http://lms.main.localhost:18000/login",
        "LOGOUT_URL": "http://lms.main.localhost:18000/logout",
        "REFRESH_ACCESS_TOKEN_ENDPOINT": "http://lms.main.localhost:18000/login_refresh",
        "ENABLE_EXAM_DASHBOARD": true,
        "EXAM_DASHBOARD_MFE_BASE_URL": "http://lms.main.localhost:2005",
        "WEBNG_PLUGIN_API_BASE_URL": "http://lms.main.localhost:18000/webng_plugin/api/v0"
    }
}
  1. The ENABLE_EXAM_DASHBOARD variable will display the Exams link, and the EXAM_DASHBOARD_MFE_BASE_URL will set the redirect value when it is clicked
  2. Restart the MFE and LMS so the settings and the new header component are integrated properly

Evidence

Exams MFE

image

Profile MFE

image

@bra-i-am bra-i-am requested a review from 01001110J October 21, 2025 16:58
@bra-i-am bra-i-am marked this pull request as ready for review October 21, 2025 17:01
@bra-i-am bra-i-am requested a review from 01001110J November 11, 2025 13:47
@bra-i-am bra-i-am merged commit cd16b32 into main Nov 11, 2025
4 checks passed
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.

2 participants

Comments