Skip to content

Conversation

@mchilagani-sonata
Copy link

@mchilagani-sonata mchilagani-sonata commented Dec 27, 2025

…uage

Added an “Academy Selection” step to the stepper, including initial setup, updated language, and i18n support; this step is hidden for users who enter directly into the Teams flow.
Added the Academy Selection stepper to the essentials/academic-selection route.
image

@codecov
Copy link

codecov bot commented Dec 27, 2025

Codecov Report

❌ Patch coverage is 86.44068% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.20%. Comparing base (35be22a) to head (30a9d95).
⚠️ Report is 24 commits behind head on main.

Files with missing lines Patch % Lines
...rc/components/Stepper/CheckoutStepperContainer.tsx 66.66% 3 Missing ⚠️
.../components/plan-details-pages/PlanDetailsPage.tsx 0.00% 3 Missing ⚠️
...onents/app/routes/loaders/checkoutStepperLoader.ts 84.61% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #128      +/-   ##
==========================================
+ Coverage   84.12%   85.20%   +1.08%     
==========================================
  Files         147      149       +2     
  Lines        2444     2528      +84     
  Branches      410      482      +72     
==========================================
+ Hits         2056     2154      +98     
+ Misses        388      374      -14     

☔ View full report in Codecov by Sentry.
📢 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.

Copy link
Collaborator

@brobro10000 brobro10000 left a comment

Choose a reason for hiding this comment

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

When creating the essentials feature, please keep in mind the teams feature is a complete feature and the original application behavior should not be interrupted as its release imminent.

Hide the essentials logic behind the feature flag and ensure the stepper remains a 3 step component for now until eseentials is ready to release. Please review the product requirements of the essentials page bearing in mind the following:

  • The essentials page is both an authenticated and unauthenticated route
  • The essentials page initial point of entry is from business.edx.org (external) so the stepper upcoming stepper (plan-details etc.) behavior is completely dependent on whether a user selects an academy or chooses to upgrade
  • The teams page initial entry point is /plan-details and the original logic should remain that if the user directly navigates to plan details with an incomplete checkout intent object the stepper flow is dependent on the product the user select (either a teams or essentials product).

I am available to pair to help get this over the line and make the requirements clear.

authenticatedUser: { userId: 12345 },
});
validateText('Continue');
expect(screen.getByText('Continue')).toBeInTheDocument();
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can remain as validateText since it does essentially the same thing.

Copy link
Author

Choose a reason for hiding this comment

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

yes

Comment on lines +52 to +54
expect(
screen.getByText('What is the name of your company or organization?'),
).toBeInTheDocument();
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can remain as validateText since it does essentially the same thing.

Copy link
Author

Choose a reason for hiding this comment

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

yes

Comment on lines +64 to +67
expect(
screen.getByText('Create a custom URL for your team'),
).toBeInTheDocument();
});
Copy link
Collaborator

Choose a reason for hiding this comment

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

This can remain as validateText since it does essentially the same thing.

Copy link
Author

Choose a reason for hiding this comment

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

yes


fireEvent.click(screen.getByText('Back'));

// expect(screen.queryByText('Plan Details')).toBeInTheDocument();
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this supposed to be commented out?

Copy link
Author

Choose a reason for hiding this comment

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

yes

Comment on lines +34 to +36
if (authenticatedUser) {
// If the user is already authenticated, redirect to AcademicSelection Page.
return redirect(CheckoutPageRoute.AcademicSelection);
Copy link
Collaborator

Choose a reason for hiding this comment

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

I would retain the original logic to PlanDetails since AcademicSelection should only be navigable via business.edx.org


const Steps = (): ReactElement => (
<>
<AcademicSelection />
Copy link
Collaborator

Choose a reason for hiding this comment

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

Hide behind feature flag since it is an incomplete feature. See rootloader.ts.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove this file

Copy link
Author

Choose a reason for hiding this comment

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

Done

Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove this file

Copy link
Author

Choose a reason for hiding this comment

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

Done

Copy link
Collaborator

Choose a reason for hiding this comment

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

Remove this file

Copy link
Author

Choose a reason for hiding this comment

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

Done

Comment on lines +15 to +27
const { step, substep } = params;

// Essentials uses substep as the step
const resolvedStep = step ?? substep ?? CheckoutStepKey.AcademicSelection;

const currentStepKey = resolvedStep as CheckoutStepKey;

const currentSubstepKey = step && substep ? substep : undefined;

const currentStep = CheckoutStepByKey[currentStepKey];
const currentSubstep = currentSubstepKey
? CheckoutSubstepByKey[currentSubstepKey]
: undefined;
Copy link
Collaborator

Choose a reason for hiding this comment

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

I believe the original implementation was correct.

Copy link
Author

Choose a reason for hiding this comment

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

yes

@brobro10000
Copy link
Collaborator

This POC should help guide you in the right direction for how to safely integrate academic selection into the current stepper process while it being gated by a feature flag.
#133

@mchilagani-sonata
Copy link
Author

This is no longer needed, as the academy selection page is being removed from the stepper flow. As noted by Alberto Del Toro and with Hamzah creating a new ticket under the new architecture, so the PR is being closed.

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