Skip to content

Commit

Permalink
Remove payouts rename notice overlay. (#10039)
Browse files Browse the repository at this point in the history
Co-authored-by: Nagesh Pai <[email protected]>
  • Loading branch information
shendy-a8c and Nagesh Pai authored Jan 1, 2025
1 parent bacc8ed commit 85865e8
Show file tree
Hide file tree
Showing 14 changed files with 4 additions and 297 deletions.
4 changes: 4 additions & 0 deletions changelog/update-9704-remove-payouts-rename-overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: minor
Type: update

Remove the overlay that announces the rename from deposits to payouts.
2 changes: 0 additions & 2 deletions client/deposits/details/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ import {
} from 'multi-currency/interface/functions';
import { depositStatusLabels } from '../strings';
import './style.scss';
import { PayoutsRenameNotice } from '../rename-notice';
import { formatDateTimeFromString } from 'wcpay/utils/date-time';
import DateFormatNotice from 'wcpay/components/date-format-notice';

Expand Down Expand Up @@ -243,7 +242,6 @@ export const DepositDetails: React.FC< DepositDetailsProps > = ( {

return (
<Page>
<PayoutsRenameNotice />
<DateFormatNotice />
<TestModeNotice currentPage="deposits" isDetailsView={ true } />
<ErrorBoundary>
Expand Down
2 changes: 0 additions & 2 deletions client/deposits/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import { __ } from '@wordpress/i18n';
import { TestModeNotice } from 'components/test-mode-notice';
import BannerNotice from 'components/banner-notice';
import DepositSchedule from 'components/deposits-overview/deposit-schedule';
import { PayoutsRenameNotice } from './rename-notice';
import { useAllDepositsOverviews } from 'data';
import { useSettings } from 'wcpay/data';
import DepositsList from './list';
Expand Down Expand Up @@ -152,7 +151,6 @@ const DepositsPage: React.FC = () => {
<Page>
<DateFormatNotice />
<TestModeNotice currentPage="deposits" />
<PayoutsRenameNotice />
<NextDepositNotice />
<DepositFailureNotice />
<DepositsList />
Expand Down
36 changes: 0 additions & 36 deletions client/deposits/rename-notice/header-image.svg

This file was deleted.

88 changes: 0 additions & 88 deletions client/deposits/rename-notice/index.tsx

This file was deleted.

77 changes: 0 additions & 77 deletions client/deposits/rename-notice/style.scss

This file was deleted.

This file was deleted.

49 changes: 0 additions & 49 deletions client/deposits/rename-notice/test/index.tsx

This file was deleted.

1 change: 0 additions & 1 deletion client/globals.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ declare global {
fraudProtection: {
isWelcomeTourDismissed?: boolean;
};
isPayoutsRenameNoticeDismissed: boolean;
progressiveOnboarding?: {
isEnabled: boolean;
isComplete: boolean;
Expand Down
2 changes: 0 additions & 2 deletions client/overview/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ import { useDisputes, useGetSettings, useSettings } from 'data';
import SandboxModeSwitchToLiveNotice from 'wcpay/components/sandbox-mode-switch-to-live-notice';
import './style.scss';
import BannerNotice from 'wcpay/components/banner-notice';
import { PayoutsRenameNotice } from 'wcpay/deposits/rename-notice';
import DateFormatNotice from 'wcpay/components/date-format-notice';

const OverviewPageError = () => {
Expand Down Expand Up @@ -197,7 +196,6 @@ const OverviewPage = () => {
{ showConnectionSuccess && <ConnectionSuccessNotice /> }
{ ! accountRejected && ! accountUnderReview && (
<ErrorBoundary>
<PayoutsRenameNotice />
<Welcome />

{ showTaskList && (
Expand Down
20 changes: 0 additions & 20 deletions client/overview/test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -352,24 +352,4 @@ describe( 'Overview page', () => {

expect( query() ).not.toBeInTheDocument();
} );

it( 'shows payout rename notice if not yet dismissed', () => {
global.wcpaySettings.isPayoutsRenameNoticeDismissed = false;

render( <OverviewPage /> );

expect(
screen.queryByText( 'Deposits are now known as Payouts!' )
).toBeInTheDocument();
} );

it( 'does not display payout rename notice if already dismissed', () => {
global.wcpaySettings.isPayoutsRenameNoticeDismissed = true;

render( <OverviewPage /> );

expect(
screen.queryByText( 'Deposits are now known as Payouts!' )
).not.toBeInTheDocument();
} );
} );
1 change: 0 additions & 1 deletion includes/admin/class-wc-payments-admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -959,7 +959,6 @@ private function get_js_settings(): array {
'fraudProtection' => [
'isWelcomeTourDismissed' => WC_Payments_Features::is_fraud_protection_welcome_tour_dismissed(),
],
'isPayoutsRenameNoticeDismissed' => WC_Payments_Features::is_payouts_rename_notice_dismissed(),
'enabledPaymentMethods' => $this->get_enabled_payment_method_ids(),
'progressiveOnboarding' => $this->account->get_progressive_onboarding_details(),
'accountDefaultCurrency' => $this->account->get_account_default_currency(),
Expand Down
9 changes: 0 additions & 9 deletions includes/class-wc-payments-features.php
Original file line number Diff line number Diff line change
Expand Up @@ -298,15 +298,6 @@ public static function is_fraud_protection_welcome_tour_dismissed(): bool {
return '1' === get_option( 'wcpay_fraud_protection_welcome_tour_dismissed', '0' );
}

/**
* Checks whether the Payouts Rename Spotlight notice was dismissed.
*
* @return bool
*/
public static function is_payouts_rename_notice_dismissed(): bool {
return '1' === get_option( 'wcpay_payouts_rename_notice_dismissed', '0' );
}

/**
* Checks whether the Stripe Billing feature is enabled.
*
Expand Down
1 change: 0 additions & 1 deletion includes/class-wc-payments.php
Original file line number Diff line number Diff line change
Expand Up @@ -1923,7 +1923,6 @@ public static function add_wcpay_options_to_woocommerce_permissions_list( $permi
'woocommerce_remind_me_later_todo_tasks',
'woocommerce_deleted_todo_tasks',
'wcpay_fraud_protection_welcome_tour_dismissed',
'wcpay_payouts_rename_notice_dismissed',
'wcpay_capability_request_dismissed_notices',
'wcpay_onboarding_eligibility_modal_dismissed',
'wcpay_next_deposit_notice_dismissed',
Expand Down

0 comments on commit 85865e8

Please sign in to comment.