Skip to content

Commit 59c5b9c

Browse files
authored
New AccountDetals: Remove the payout icon status (#11093)
1 parent 39c94b6 commit 59c5b9c

File tree

5 files changed

+10
-17
lines changed

5 files changed

+10
-17
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Significance: patch
2+
Type: update
3+
Comment: New Account Details: Remove the payout icon status to be consistent with account status (without icon)
4+
5+

client/components/account-details/__tests__/index.test.tsx

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ describe( 'AccountDetails', () => {
4747
payout_status: {
4848
text: 'Available',
4949
background_color: 'green',
50-
icon: 'published',
5150
},
5251
banner: null,
5352
};
@@ -70,7 +69,6 @@ describe( 'AccountDetails', () => {
7069
payout_status: {
7170
text: 'Disabled',
7271
background_color: 'red',
73-
icon: 'error',
7472
},
7573
banner: {
7674
text: 'Your account has been restricted by Stripe.',
@@ -98,7 +96,6 @@ describe( 'AccountDetails', () => {
9896
payout_status: {
9997
text: 'Disabled',
10098
background_color: 'red',
101-
icon: 'error',
10299
},
103100
banner: {
104101
text: 'Your account has been rejected.',
@@ -127,7 +124,6 @@ describe( 'AccountDetails', () => {
127124
payout_status: {
128125
text: 'Available in 2 days',
129126
background_color: 'yellow',
130-
icon: 'caution',
131127
popover: {
132128
text: 'Payouts are processed within 2 business days.',
133129
cta_text: 'Learn more',
@@ -154,7 +150,6 @@ describe( 'AccountDetails', () => {
154150
payout_status: {
155151
text: 'Available',
156152
background_color: 'green',
157-
icon: 'published',
158153
},
159154
banner: null,
160155
};
@@ -180,7 +175,6 @@ describe( 'AccountDetails', () => {
180175
payout_status: {
181176
text: 'Available',
182177
background_color: 'green',
183-
icon: 'published',
184178
},
185179
banner: null,
186180
};
@@ -206,7 +200,6 @@ describe( 'AccountDetails', () => {
206200
payout_status: {
207201
text: 'Available',
208202
background_color: 'green',
209-
icon: 'published',
210203
},
211204
banner: null,
212205
};

client/components/account-details/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import React from 'react';
77
import { __ } from '@wordpress/i18n';
88
import { addQueryArgs } from '@wordpress/url';
9-
import { Card, CardBody, CardHeader, Flex } from '@wordpress/components';
9+
import { Card, CardBody, CardHeader } from '@wordpress/components';
1010

1111
/**
1212
* Internal dependencies

client/components/account-details/payout-status-wrapper.tsx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import HelpOutlineIcon from 'gridicons/dist/help-outline';
1414
import Chip from 'wcpay/components/chip';
1515
import { ClickTooltip } from 'wcpay/components/tooltip';
1616
import { AccountDetailsData } from 'wcpay/types/account/account-details';
17-
import { getChipTypeFromColor, getIconByName } from './utils';
17+
import { getChipTypeFromColor } from './utils';
1818

1919
const PayoutStatus: React.FC< {
2020
payoutStatus: AccountDetailsData[ 'payout_status' ];
@@ -23,11 +23,7 @@ const PayoutStatus: React.FC< {
2323

2424
return (
2525
<Flex align="center" gap={ 0 } justify="flex-start">
26-
<Chip
27-
type={ chipType }
28-
message={ payoutStatus.text }
29-
icon={ getIconByName( payoutStatus.icon ) }
30-
/>
26+
<Chip type={ chipType } message={ payoutStatus.text } />
3127
{ payoutStatus.popover && (
3228
<ClickTooltip
3329
className={ 'payout-click-tooltip' }

client/types/account/account-details.d.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,10 @@ export interface AccountDetailsData {
1616
payout_status: {
1717
text: string;
1818
background_color: StatusBackgroundColor;
19-
icon?: IconName;
2019
popover?: {
2120
text: string;
22-
cta_text: string;
23-
cta_link: string;
21+
cta_text?: string;
22+
cta_link?: string;
2423
} | null;
2524
};
2625
banner?: {

0 commit comments

Comments
 (0)