Fix group avatar
This commit is contained in:
parent
73335ec3ff
commit
2ed61fd763
|
@ -28,6 +28,8 @@ const DialogCard = (props: DialogProps) => {
|
|||
?.map((companion) => companion.name)
|
||||
.join(', ')
|
||||
)
|
||||
|
||||
console.log('!!! companions:', companions())
|
||||
return (
|
||||
<Show when={props.members}>
|
||||
<div
|
||||
|
@ -40,8 +42,8 @@ const DialogCard = (props: DialogProps) => {
|
|||
>
|
||||
<div class={styles.avatar}>
|
||||
<Switch fallback={<DialogAvatar name={props.members[0].name} url={props.members[0].userpic} />}>
|
||||
<Match when={companions().length > 2}>
|
||||
<GroupDialogAvatar users={companions()} />
|
||||
<Match when={props.members.length >= 2}>
|
||||
<GroupDialogAvatar users={props.members} />
|
||||
</Match>
|
||||
</Switch>
|
||||
</div>
|
||||
|
|
|
@ -57,7 +57,6 @@ export const InboxView = () => {
|
|||
changeSearchParam('chat', `${chat.id}`)
|
||||
try {
|
||||
const response = await loadMessages({ chat: chat.id })
|
||||
console.log('!!! response:', response)
|
||||
setMessages(response as unknown as MessageType[])
|
||||
// TODO: one client recreating
|
||||
} catch (error) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user