This commit is contained in:
Joshua T Flowers 2021-11-15 15:09:02 -05:00 committed by GitHub
parent 30e9922986
commit 331ca075c4
4 changed files with 7 additions and 9 deletions

View File

@ -12,13 +12,12 @@ import { recordEvent } from '@woocommerce/tracks';
import { PartnerCard } from '../components/partner-card';
import logo from './logo.png';
export const Card = ( { isPending, task } ) => {
export const Card = ( { task } ) => {
const { avalaraActivated } = task.additionalData;
return (
<PartnerCard
name={ __( 'Avalara', 'woocommerce-admin' ) }
isPending={ isPending }
logo={ logo }
description={ __(
'Powerful all-in-one tax tool',

View File

@ -18,7 +18,7 @@ export const PartnerCard: React.FC< {
terms: string;
actionText: string;
onClick: () => void;
isPending: boolean;
isBusy?: boolean;
} > = ( {
name,
logo,
@ -27,7 +27,7 @@ export const PartnerCard: React.FC< {
terms,
actionText,
onClick,
isPending,
isBusy,
} ) => {
return (
<div className="woocommerce-tax-partner-card">
@ -63,8 +63,8 @@ export const PartnerCard: React.FC< {
<Button
isSecondary
onClick={ onClick }
isBusy={ isPending }
disabled={ isPending }
isBusy={ isBusy }
disabled={ isBusy }
>
{ actionText }
</Button>

View File

@ -238,7 +238,7 @@ const Tax = ( { onComplete, query, task } ) => {
}
return (
<Partners>
<Partners { ...childProps }>
{ partners.map( ( partner ) =>
createElement( partner.card, {
key: partner.id,

View File

@ -14,11 +14,10 @@ import { PartnerCard } from '../components/partner-card';
import logo from './logo.png';
import { TaxChildProps } from '../utils';
export const Card: React.FC< TaxChildProps > = ( { isPending } ) => {
export const Card: React.FC< TaxChildProps > = () => {
return (
<PartnerCard
name={ __( 'WooCommerce Tax', 'woocommerce-admin' ) }
isPending={ isPending }
logo={ logo }
description={ __( 'Best for new stores', 'woocommerce-admin' ) }
benefits={ [