aboutsummaryrefslogtreecommitdiff
path: root/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2021-02-13 16:35:39 +0800
committercrupest <crupest@outlook.com>2021-02-13 16:35:39 +0800
commitaeed3cb80d8c0a62d0ccc565733c4a213759c5bd (patch)
treefd00577d63c396bcbbd72a31d2f2aeda2fff6218 /FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
parent8211994b7175f2ad04663abc0c2605eb96143841 (diff)
downloadtimeline-aeed3cb80d8c0a62d0ccc565733c4a213759c5bd.tar.gz
timeline-aeed3cb80d8c0a62d0ccc565733c4a213759c5bd.tar.bz2
timeline-aeed3cb80d8c0a62d0ccc565733c4a213759c5bd.zip
...
Diffstat (limited to 'FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx')
-rw-r--r--FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx10
1 files changed, 3 insertions, 7 deletions
diff --git a/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx b/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
index 920f504d..63da6f3c 100644
--- a/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
+++ b/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
@@ -1,12 +1,10 @@
import React from "react";
-import { useAvatar } from "@/services/user";
-
-import BlobImage from "../common/BlobImage";
import TimelineCardTemplate, {
TimelineCardTemplateProps,
} from "../timeline-common/TimelineCardTemplate";
import { TimelineCardComponentProps } from "../timeline-common/TimelinePageTemplateUI";
+import UserAvatar from "../common/user/UserAvatar";
export type OrdinaryTimelineManageItem = "delete";
@@ -16,8 +14,6 @@ const TimelineInfoCard: React.FC<TimelineInfoCardProps> = (props) => {
const { timeline, operations } = props;
const { onManage, onMember } = operations;
- const avatar = useAvatar(timeline?.owner?.username);
-
return (
<TimelineCardTemplate
infoArea={
@@ -27,8 +23,8 @@ const TimelineInfoCard: React.FC<TimelineInfoCardProps> = (props) => {
<small className="ml-3 text-secondary">{timeline.name}</small>
</h3>
<div className="align-middle">
- <BlobImage
- blob={avatar}
+ <UserAvatar
+ username={timeline.owner.username}
className="avatar small rounded-circle mr-3"
/>
{timeline.owner.nickname}