Skip to content

feat: add pathway cards and badges - #148

Open
navinkarkera wants to merge 15 commits into
openedx:masterfrom
open-craft:navin/fal-4373/card-badge
Open

feat: add pathway cards and badges#148
navinkarkera wants to merge 15 commits into
openedx:masterfrom
open-craft:navin/fal-4373/card-badge

Conversation

@navinkarkera

@navinkarkera navinkarkera commented Aug 7, 2026

Copy link
Copy Markdown

Related to: #152

Description:

  • Adds PathwayCard and course/pathway badges.
  • Adds shared catalog-card badge styling and exports the pathway card.
  • Adds HomePathwayCardSlot with frontend plugin support.
  • Adds card and slot-related tests.
  • Adds the ENABLE_PATHWAY_PILOT_UI configuration gate. The gate keeps the UI disabled by default as the backend is not ready yet.

Related links:

Test instructions

From the repository root, apply pathway-badges-ui-demo.patch to add dummy pathway cards:

git apply --check pathway-badges-ui-demo.patch
git apply pathway-badges-ui-demo.patch

Set ENABLE_PATHWAY_PILOT_UI=true, start the app, and verify pathway cards and badges render. Unset it or set it to any value other than true, restart the app, and verify pathway UI and badges do not render.

Screenshot:

image

@openedx-webhooks openedx-webhooks added open-source-contribution PR author is not from Axim or 2U core contributor PR author is a Core Contributor (who may or may not have write access to this repo). labels Aug 7, 2026
@openedx-webhooks

openedx-webhooks commented Aug 7, 2026

Copy link
Copy Markdown

Thanks for the pull request, @navinkarkera!

This repository is currently maintained by @openedx/committers-frontend.

Once you've gone through the following steps feel free to tag them in a comment and let them know that your changes are ready for engineering review.

🔘 Get product approval

If you haven't already, check this list to see if your contribution needs to go through the product review process.

  • If it does, you'll need to submit a product proposal for your contribution, and have it reviewed by the Product Working Group.
    • This process (including the steps you'll need to take) is documented here.
  • If it doesn't, simply proceed with the next step.
🔘 Provide context

To help your reviewers and other members of the community understand the purpose and larger context of your changes, feel free to add as much of the following information to the PR description as you can:

  • Dependencies

    This PR must be merged before / after / at the same time as ...

  • Blockers

    This PR is waiting for OEP-1234 to be accepted.

  • Timeline information

    This PR must be merged by XX date because ...

  • Partner information

    This is for a course on edx.org.

  • Supporting documentation
  • Relevant Open edX discussion forum threads
🔘 Get a green build

If one or more checks are failing, continue working on your changes until this is no longer the case and your build turns green.

Details
Where can I find more information?

If you'd like to get more details on all aspects of the review process for open source pull requests (OSPRs), check out the following resources:

When can I expect my changes to be merged?

Our goal is to get community contributions seen and reviewed as efficiently as possible.

However, the amount of time that it takes to review and merge a PR can vary significantly based on factors such as:

  • The size and impact of the changes that it introduces
  • The need for product review
  • Maintenance status of the parent repository

💡 As a result it may take up to several weeks or months to complete a review and merge your PR.

@codecov

codecov Bot commented Aug 7, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.95%. Comparing base (b8aa4dd) to head (c1c65f4).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #148      +/-   ##
==========================================
+ Coverage   98.89%   98.95%   +0.06%     
==========================================
  Files         106      109       +3     
  Lines        1083     1149      +66     
  Branches      185      217      +32     
==========================================
+ Hits         1071     1137      +66     
  Misses         12       12              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

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

@navinkarkera
navinkarkera marked this pull request as ready for review August 7, 2026 13:23
@navinkarkera
navinkarkera requested a review from ChrisChV August 7, 2026 13:23
@mphilbrick211 mphilbrick211 moved this from Needs Triage to Ready for Review in Contributions Aug 7, 2026

@ChrisChV ChrisChV left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

@navinkarkera Looks good 👍

  • I tested this: I followed the testing instructions
  • I read through the code and considered the security, stability and performance implications of the changes.
  • I tested that the UI can be used with a keyboard only (tab order, keyboard controls).
  • Includes tests for bugfixes and/or features added.
  • Includes documentation

Comment thread src/generic/pathway-card/index.tsx Outdated
import type { PathwayCardProps } from './types';
import { getFullImageUrl, getStartDateDisplay } from '../course-card/utils';

const isValidCssColor = (value: string) => {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

I think this function should be in a utils file

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Done.

Comment thread src/generic/pathway-card/types.ts Outdated
Comment on lines +3 to +12
pathwayId?: string;
pathwayName?: string;
pathwayOrg?: string;
pathwayCourseCount?: number;
pathwayImageUrl?: string;
pathwayStartDate?: string;
pathwayAdvertisedStart?: string;
pathwayType?: string;
pathwayTypeBackgroundColor?: string;
pathwayTypeTextColor?: string;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Is it necessary for all these props to have the 'pathway' prefix? Given the interface name 'PathwayCardProps', I think it's already implied that those props belong to the pathway.

@navinkarkera navinkarkera Aug 10, 2026

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

It was to match with CourseCardProps but not really useful. Updated here: 97b622a

@navinkarkera
navinkarkera force-pushed the navin/fal-4373/card-badge branch from 97b622a to c1c65f4 Compare August 11, 2026 04:45
@navinkarkera

Copy link
Copy Markdown
Author

@feanil Can you review and merge this pr.

@feanil

feanil commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

@navinkarkera I'm not super familiar with this project so I'm not the right person to review this but I've pinged the project team to find an appropriate reviewer.

@mphilbrick211 mphilbrick211 moved this from Ready for Review to In Eng Review in Contributions Aug 19, 2026
@arbrandes

Copy link
Copy Markdown
Contributor

Heads up: the frontend-base conversion of Catalog will in all likelihood land before this PR. (See the announcement.) I apologize for the inconvenience, but once that happens (probably this week), the feature will have to be refactored accordingly.

I suggest not closing this PR, though: once the legacy-mfe branch exists, just change this PR's target to it. However, this means this will automatically become a backport, and a new PR to master will need to be reviewed and merged before this one is considered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core contributor PR author is a Core Contributor (who may or may not have write access to this repo). open-source-contribution PR author is not from Axim or 2U

Projects

Status: In Eng Review

Development

Successfully merging this pull request may close these issues.

6 participants