mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-05 08:59:14 +08:00
⏪️ Restore the payment method screen for all users
This commit is contained in:
parent
53c90537f5
commit
7369b8dbda
2 changed files with 2 additions and 5 deletions
|
@ -56,14 +56,12 @@ const filterSteps = ( steps, conditions ) => {
|
|||
);
|
||||
};
|
||||
|
||||
export const getSteps = ( flags, isCasualSeller ) => {
|
||||
export const getSteps = ( flags ) => {
|
||||
const steps = filterSteps( ALL_STEPS, [
|
||||
// Casual selling: Unlock the "Personal Account" choice.
|
||||
( step ) => flags.canUseCasualSelling || step.id !== 'business',
|
||||
// Card payments: Unlocks the "Extended Checkout" choice.
|
||||
( step ) => flags.canUseCardPayments || step.id !== 'methods',
|
||||
// Card payments are only available for business sellers.
|
||||
( step ) => ! isCasualSeller || step.id !== 'methods',
|
||||
] );
|
||||
|
||||
const totalStepsCount = steps.length;
|
||||
|
|
|
@ -6,9 +6,8 @@ import OnboardingNavigation from './Components/Navigation';
|
|||
|
||||
const OnboardingScreen = () => {
|
||||
const { step, setStep, flags } = OnboardingHooks.useSteps();
|
||||
const { isCasualSeller } = OnboardingHooks.useBusiness();
|
||||
|
||||
const Steps = getSteps( flags, isCasualSeller );
|
||||
const Steps = getSteps( flags );
|
||||
const currentStep = getCurrentStep( step, Steps );
|
||||
|
||||
const handleNext = () => setStep( currentStep.nextStep );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue