import React from 'react'; import { MemoConversationListItemWithDetails } from '../ConversationListItem'; import { RowRendererParamsType } from '../LeftPane'; import { AutoSizer, List } from 'react-virtualized'; import { LeftPaneSectionHeader } from './LeftPaneSectionHeader'; import { useSelector } from 'react-redux'; import { getDirectContacts, getLeftPaneLists } from '../../state/selectors/conversations'; import { isSearching } from '../../state/selectors/search'; const renderRow = ({ index, key, style }: RowRendererParamsType) => { const showSearch = useSelector(isSearching); const lists = showSearch ? undefined : useSelector(getLeftPaneLists); const directContacts = lists?.contacts || []; const item = directContacts[index]; return ; }; const ContactListItemSection = () => { const directContacts = useSelector(getDirectContacts); if (!directContacts) { return null; } const length = Number(directContacts.length); return (
{({ height, width }) => ( )}
); }; export const LeftPaneContactSection = () => { return (
); };