Skip to content
This repository was archived by the owner on Jun 2, 2024. It is now read-only.
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore: avatar
  • Loading branch information
hi-ogawa committed Apr 7, 2024
commit cfa12fc7e88cc2a33a7c947dd1b2ea1196ae50fa
7 changes: 5 additions & 2 deletions src/routes/contacts/[contactId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,10 @@ export default async function Contact(props: PageProps) {
<div>
<img
alt={`${contact.first} ${contact.last} avatar`}
key={contact.avatar}
src={contact.avatar}
src={
contact.avatar ||
`https://avatar.vercel.sh/${contact.first}${contact.last}`
}
/>
</div>

Expand Down Expand Up @@ -59,6 +61,7 @@ export default async function Contact(props: PageProps) {
function Favorite(props: { contact: ContactRecord }) {
const favorite = props.contact.favorite;

// TODO
return (
<form method="post">
<button
Expand Down