Merge pull request #3547 from woocommerce/PCP-4425-react-onboarding-wizard-step-4-should-be-skipped

Skip "Payment Methods" step for branded-only + BCDC and casual sellers (4425)
This commit is contained in:
Niklas Gutberlet 2025-08-04 19:34:36 +02:00 committed by GitHub
commit af18a7bcdd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -64,10 +64,19 @@ export const getSteps = ( flags ) => {
// Casual selling: Unlock the "Personal Account" choice.
( step ) => flags.canUseCasualSelling || step.id !== 'business',
// Skip payment methods screen.
( step ) =>
step.id !== 'methods' ||
( ! flags.shouldSkipPaymentMethods &&
! ( ownBrandOnly && isCasualSeller ) ),
( step ) => {
if ( step.id !== 'methods' ) {
return true;
}
const isBrandedBCDC = ownBrandOnly && ! flags.canUseCardPayments;
const shouldSkip =
flags.shouldSkipPaymentMethods ||
isCasualSeller ||
isBrandedBCDC;
return ! shouldSkip;
},
] );
const totalStepsCount = steps.length;