import type { ChatMember } from '../../graphql/schema/chat.gen' import { clsx } from 'clsx' import { For } from 'solid-js' import DialogAvatar from './DialogAvatar' import './DialogCard.module.scss' import styles from './GroupDialogAvatar.module.scss' type Props = { users: ChatMember[] } const GroupDialogAvatar = (props: Props) => { const slicedUsers = () => { if (props.users.length > 3) { return props.users.slice(0, 2) } return props.users.slice(0, 3) } return (
{(user) => ( )} {props.users.length > 3 && (
= 100 })}> {++props.users.length}
)}
) } export default GroupDialogAvatar