From 3cd0f1bc1c0b009f77c88163fb70d3d9ea80234b Mon Sep 17 00:00:00 2001 From: K Om Senapati Date: Fri, 11 Oct 2024 16:26:35 +0530 Subject: [PATCH] [MM-60839] Remove unused 'webapp/channels/src/components/admin_console/billing/payment_details.tsx' (#28652) --- .../admin_console/billing/payment_details.tsx | 64 ------------------- webapp/channels/src/i18n/en.json | 3 - 2 files changed, 67 deletions(-) delete mode 100644 webapp/channels/src/components/admin_console/billing/payment_details.tsx diff --git a/webapp/channels/src/components/admin_console/billing/payment_details.tsx b/webapp/channels/src/components/admin_console/billing/payment_details.tsx deleted file mode 100644 index 85db5604ad..0000000000 --- a/webapp/channels/src/components/admin_console/billing/payment_details.tsx +++ /dev/null @@ -1,64 +0,0 @@ -// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved. -// See LICENSE.txt for license information. - -import React from 'react'; -import {FormattedMessage} from 'react-intl'; -import {useSelector} from 'react-redux'; - -import FormattedMarkdownMessage from 'components/formatted_markdown_message'; -import CardImage from 'components/payment_form/card_image'; - -import type {GlobalState} from 'types/store'; - -export interface PaymentDetailsProps { - children?: React.ReactNode; -} - -const PaymentDetails: React.FC = ({children}: PaymentDetailsProps) => { - const customerPaymentInfo = useSelector((state: GlobalState) => state.entities.cloud.customer); - - if (!customerPaymentInfo?.payment_method && !customerPaymentInfo?.billing_address) { - return null; - } - const address = customerPaymentInfo.billing_address; - - return ( -
- -
- -
- -
-
- -
-
-
{address.line1}
- {address.line2 &&
{address.line2}
} -
{`${address.city}, ${address.state}, ${address.postal_code}`}
-
{address.country}
-
- {children} -
- ); -}; - -export default PaymentDetails; diff --git a/webapp/channels/src/i18n/en.json b/webapp/channels/src/i18n/en.json index 21459aa749..f8b32ff3c2 100644 --- a/webapp/channels/src/i18n/en.json +++ b/webapp/channels/src/i18n/en.json @@ -323,9 +323,6 @@ "admin.billing.history.title": "Billing History", "admin.billing.history.total": "Total", "admin.billing.history.transactions": "Transactions", - "admin.billing.payment_info.billingAddress": "Billing Address", - "admin.billing.payment_info.cardBrandAndDigits": "{brand} ending in {digits}", - "admin.billing.payment_info.cardExpiry": "Expires {month}/{year}", "admin.billing.subscription.byClickingYouAgree": "By clicking {buttonContent}, you agree to the {legalText}", "admin.billing.subscription.cancelSubscriptionSection.contactUs": "Contact Us", "admin.billing.subscription.cancelSubscriptionSection.description": "At this time, deleting a workspace can only be done with the help of a customer support representative.",