diff --git a/src/customers/components/CustomerInfo/CustomerInfo.tsx b/src/customers/components/CustomerInfo/CustomerInfo.tsx index ca158a994..26c6893a9 100644 --- a/src/customers/components/CustomerInfo/CustomerInfo.tsx +++ b/src/customers/components/CustomerInfo/CustomerInfo.tsx @@ -3,21 +3,15 @@ import CardContent from "@material-ui/core/CardContent"; import { makeStyles } from "@material-ui/core/styles"; import TextField from "@material-ui/core/TextField"; import Typography from "@material-ui/core/Typography"; -import moment from "moment-timezone"; import React from "react"; import { FormattedMessage, useIntl } from "react-intl"; import CardTitle from "@saleor/components/CardTitle"; import Grid from "@saleor/components/Grid"; import Hr from "@saleor/components/Hr"; -import Skeleton from "@saleor/components/Skeleton"; import { commonMessages } from "@saleor/intl"; -import { CustomerDetails_user } from "../../types/CustomerDetails"; const useStyles = makeStyles(theme => ({ - cardTitle: { - height: 64 - }, content: { paddingTop: theme.spacing(2) }, @@ -29,8 +23,7 @@ const useStyles = makeStyles(theme => ({ } })); -export interface CustomerDetailsProps { - customer: CustomerDetails_user; +export interface CustomerInfoProps { data: { firstName: string; lastName: string; @@ -45,8 +38,8 @@ export interface CustomerDetailsProps { onChange: (event: React.ChangeEvent) => void; } -const CustomerDetails: React.FC = props => { - const { customer, data, disabled, errors, onChange } = props; +const CustomerInfo: React.FC = props => { + const { data, disabled, errors, onChange } = props; const classes = useStyles(props); const intl = useIntl(); @@ -54,24 +47,11 @@ const CustomerDetails: React.FC = props => { return ( - - {customer && customer.dateJoined ? ( - - - - ) : ( - - )} - + } /> @@ -124,5 +104,5 @@ const CustomerDetails: React.FC = props => { ); }; -CustomerDetails.displayName = "CustomerDetails"; -export default CustomerDetails; +CustomerInfo.displayName = "CustomerInfo"; +export default CustomerInfo;