Skip to content

Commit

Permalink
fix: pass the test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
hinakhadim committed Dec 8, 2023
1 parent f2bccff commit 3cc0477
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
3 changes: 3 additions & 0 deletions src/learning-header/AuthenticatedUserDropdown.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ const AuthenticatedUserDropdown = ({ intl, username }) => {
src={`${getConfig().LMS_BASE_URL}/static/indigo/images/profile.svg`}
alt="Image description"
/>
<span data-hj-suppress className="sr-only">
{username}
</span>
</Dropdown.Toggle>
<Dropdown.Menu className="dropdown-menu-right">
<a href={`${getConfig().LMS_BASE_URL}/dashboard`} className="pgn__dropdown-item dropdown-item h-desktop">My Courses</a>
Expand Down
6 changes: 4 additions & 2 deletions src/learning-header/LearningHeader.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ LinkedLogo.propTypes = {
};

const LearningHeader = ({
courseOrg, courseTitle, intl, showUserDropdown,
courseOrg, courseNumber, courseTitle, intl, showUserDropdown,
}) => {
const { authenticatedUser } = useContext(AppContext);

Expand All @@ -47,7 +47,7 @@ const LearningHeader = ({
<div className="flex-grow-1 course-title-lockup" style={{ lineHeight: 1 }}>
<div className="course-info-header">
<span className="d-block title">{courseTitle}</span>
<span className="d-block org">{courseOrg}</span>
<span className="d-block org">{courseOrg} {courseNumber}</span>
</div>
<div className="nav-course">
<a href={`${getConfig().LMS_BASE_URL}/dashboard`}>
Expand Down Expand Up @@ -75,13 +75,15 @@ const LearningHeader = ({

LearningHeader.propTypes = {
courseOrg: PropTypes.string,
courseNumber: PropTypes.string,
courseTitle: PropTypes.string,
intl: intlShape.isRequired,
showUserDropdown: PropTypes.bool,
};

LearningHeader.defaultProps = {
courseOrg: null,
courseNumber: null,
courseTitle: null,
showUserDropdown: true,
};
Expand Down

0 comments on commit 3cc0477

Please sign in to comment.