[resumes][feat] update icon image

ailing/undo-fix
Keane Chan 2 years ago
parent 6926aa41cd
commit 3fe4f760ac
No known key found for this signature in database
GPG Key ID: 32718398E1E9F87C

@ -1,7 +1,6 @@
import clsx from 'clsx'; import clsx from 'clsx';
import { formatDistanceToNow } from 'date-fns'; import { formatDistanceToNow } from 'date-fns';
import { useState } from 'react'; import { useState } from 'react';
import { FaceSmileIcon } from '@heroicons/react/24/outline';
import ResumeCommentEditForm from './comment/ResumeCommentEditForm'; import ResumeCommentEditForm from './comment/ResumeCommentEditForm';
import ResumeCommentReplyForm from './comment/ResumeCommentReplyForm'; import ResumeCommentReplyForm from './comment/ResumeCommentReplyForm';
@ -29,24 +28,16 @@ export default function ResumeCommentListItem({
<div className="min-w-fit"> <div className="min-w-fit">
<div className="flex flex-row space-x-3 align-top"> <div className="flex flex-row space-x-3 align-top">
{/* Image Icon */} {/* Image Icon */}
{comment.user.image ? (
<img <img
alt={comment.user.name ?? 'Reviewer'} alt={comment.user.name ?? 'Reviewer'}
className={clsx( className={clsx(
'mt-1 rounded-full', 'mt-1 rounded-full',
comment.parentId ? 'h-8 w-8' : 'h-10 w-10', comment.parentId ? 'h-7 w-7' : 'h-9 w-9',
)} )}
src={comment.user.image!} src={`https://avatars.dicebear.com/api/gridy/${
comment.user.name ?? 'random'
}.svg`}
/> />
) : (
<FaceSmileIcon
className={clsx(
'mt-1 rounded-full',
comment.parentId ? 'h-6 w-6' : 'h-8 w-8 ',
)}
/>
)}
<div className="flex w-full flex-col space-y-1"> <div className="flex w-full flex-col space-y-1">
{/* Name and creation time */} {/* Name and creation time */}
<div className="flex flex-row items-center space-x-2"> <div className="flex flex-row items-center space-x-2">

Loading…
Cancel
Save