import React from 'react' ; import { User as UserType } from './usersSlice' ; import { Box , Flex , Text } from '@chakra-ui/core/dist' ; type Props = { user : UserType ; } ; export const User = ( { user : { first , last , email , address , created } } ) => { return ( < > < Flex direction = { 'column' } p = { 3 } borderWidth = { '2px' } > < Text fontWeight = { 'bold' } > { first } { last } < /Text> < Box fontSize = { 'sm' } > < Text isTruncated > { email } < /Text> < Text > { address } < /Text> < Text > { created } < /Text> < /Box> < /Flex> < />); } ;