Keyboard shortcuts and accessibility
This commit is contained in:
parent
8590a047c7
commit
20a892247f
87 changed files with 3652 additions and 711 deletions
|
@ -5,20 +5,30 @@ import { StateType } from '../reducer';
|
|||
|
||||
import { TimelineItem } from '../../components/conversation/TimelineItem';
|
||||
import { getIntl } from '../selectors/user';
|
||||
import { getMessageSelector } from '../selectors/conversations';
|
||||
import {
|
||||
getMessageSelector,
|
||||
getSelectedMessage,
|
||||
} from '../selectors/conversations';
|
||||
|
||||
type ExternalProps = {
|
||||
id: string;
|
||||
conversationId: string;
|
||||
};
|
||||
|
||||
const mapStateToProps = (state: StateType, props: ExternalProps) => {
|
||||
const { id } = props;
|
||||
const { id, conversationId } = props;
|
||||
|
||||
const messageSelector = getMessageSelector(state);
|
||||
const item = messageSelector(id);
|
||||
|
||||
const selectedMessage = getSelectedMessage(state);
|
||||
const isSelected = Boolean(selectedMessage && id === selectedMessage.id);
|
||||
|
||||
return {
|
||||
item,
|
||||
id,
|
||||
conversationId,
|
||||
isSelected,
|
||||
i18n: getIntl(state),
|
||||
};
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue