Skip to content

Commit

Permalink
Merge pull request #7 from BeiyanYunyi/dev
Browse files Browse the repository at this point in the history
🐛 Avatar should not be shrinked
  • Loading branch information
BeiyanYunyi committed Dec 19, 2023
2 parents 119c20c + 10e49eb commit 9e88e67
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/CommentCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const CommentCard: Component<{ content: ReactiveComment; rootId: string }> = (pr
const { locale, commentClassName } = configProvider;
const time = createMemo(() => getTimeAgo(new Date(props.content.time), now(), locale()));
return (
<div id={props.content.objectId} class="sds-comment flex p-2 pe-0">
<div id={props.content.objectId} class="sds-comment flex flex-shrink-0 p-2 pe-0">
<div aria-hidden class="me-3 relative">
<Show when={props.content.avatar}>
<img src={props.content.avatar} alt={props.content.nick} class="sds-avatar" />
Expand Down
1 change: 1 addition & 0 deletions src/controllers/commentBoxState.ts
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ export const submitComment = () => {
target.setComment(resComment.comment);
if (resComment.orig) target.setOrig(resComment.orig);
setEdit(null);
clearReplyState();
} else if (resComment.rid) {
const target = data().find((item) => item.objectId === resComment.rid);
if (!target) return null;
Expand Down

0 comments on commit 9e88e67

Please sign in to comment.