import React from 'react'; import Container from './container'; import Connect from './connect'; import { Card, CardBody, CardDivider, __experimentalHeading as Heading, } from '@wordpress/components'; import { __ } from '@wordpress/i18n'; import './style.scss'; type OnboardingState = 'needs_connection' | 'needs_tos_only'; interface ShippingSettingsProps { authReturnUrl: string; isCountrySupported: boolean; isCurrencySupported: boolean; storeCountryName: string; storeCurrency: string; onboardingState?: OnboardingState; } const Onboarding = ( { authReturnUrl, isCountrySupported, isCurrencySupported, storeCountryName, storeCurrency, onboardingState = 'needs_connection', }: ShippingSettingsProps ) => { const isTosOnly = onboardingState === 'needs_tos_only'; return ( { isTosOnly ? __( 'Almost ready', 'woocommerce-shipping' ) : __( 'Connect your store to WordPress.com', 'woocommerce-shipping' ) } { isTosOnly ? ( <>

{ __( 'Your store is already connected to WordPress.com — you’re just one step away from printing discounted shipping labels with just a few clicks from your WooCommerce dashboard.', 'woocommerce-shipping' ) }

{ __( 'Review our terms below to enable WooCommerce Shipping and start using Automattic’s best-in-class infrastructure, so your store stays more stable and faster.', 'woocommerce-shipping' ) }

) : ( <>

{ __( 'Save time and money with WooCommerce Shipping by printing discounted shipping labels with just a few clicks from your WooCommerce dashboard.', 'woocommerce-shipping' ) }

{ __( 'With WooCommerce Shipping, critical services are hosted on Automattic’s best-in-class infrastructure, rather than relying on your store’s hosting. That means your store will be more stable and faster.', 'woocommerce-shipping' ) }

) }
); }; export default Onboarding;