Fix: Consistent avatars for show pages (#1776)
- consistent avatars for show pages
This commit is contained in:
@ -3,7 +3,7 @@ import { Tooltip } from 'react-tooltip';
|
||||
import styled from '@emotion/styled';
|
||||
import { v4 as uuidV4 } from 'uuid';
|
||||
|
||||
import { Avatar } from '@/users/components/Avatar';
|
||||
import { Avatar, AvatarType } from '@/users/components/Avatar';
|
||||
import {
|
||||
beautifyExactDateTime,
|
||||
beautifyPastDateRelativeToNow,
|
||||
@ -18,6 +18,7 @@ type OwnProps = {
|
||||
date: string;
|
||||
renderTitleEditComponent?: () => JSX.Element;
|
||||
onUploadPicture?: (file: File) => void;
|
||||
avatarType: AvatarType;
|
||||
};
|
||||
|
||||
const StyledShowPageSummaryCard = styled.div`
|
||||
@ -77,6 +78,7 @@ export const ShowPageSummaryCard = ({
|
||||
logoOrAvatar,
|
||||
title,
|
||||
date,
|
||||
avatarType,
|
||||
renderTitleEditComponent,
|
||||
onUploadPicture,
|
||||
}: OwnProps) => {
|
||||
@ -102,7 +104,7 @@ export const ShowPageSummaryCard = ({
|
||||
size="xl"
|
||||
colorId={id}
|
||||
placeholder={title}
|
||||
type="rounded"
|
||||
type={avatarType}
|
||||
/>
|
||||
<StyledFileInput
|
||||
ref={inputFileRef}
|
||||
|
||||
@ -90,6 +90,7 @@ export const CompanyShow = () => {
|
||||
renderTitleEditComponent={() => (
|
||||
<CompanyNameEditableField company={company} />
|
||||
)}
|
||||
avatarType="squared"
|
||||
/>
|
||||
<PropertyBox extraPadding={true}>
|
||||
{companyShowFieldDefinition.map((fieldDefinition) => {
|
||||
|
||||
@ -116,6 +116,7 @@ export const PersonShow = () => {
|
||||
)
|
||||
}
|
||||
onUploadPicture={onUploadPicture}
|
||||
avatarType="rounded"
|
||||
/>
|
||||
<PropertyBox extraPadding={true}>
|
||||
{personShowFieldDefinition.map((fieldDefinition) => {
|
||||
|
||||
Reference in New Issue
Block a user