Keyboard shortcuts and accessibility
This commit is contained in:
parent
8590a047c7
commit
20a892247f
87 changed files with 3652 additions and 711 deletions
|
@ -33,7 +33,7 @@ export class EmbeddedContact extends React.Component<Props> {
|
|||
const direction = isIncoming ? 'incoming' : 'outgoing';
|
||||
|
||||
return (
|
||||
<div
|
||||
<button
|
||||
className={classNames(
|
||||
'module-embedded-contact',
|
||||
withContentAbove
|
||||
|
@ -43,15 +43,21 @@ export class EmbeddedContact extends React.Component<Props> {
|
|||
? 'module-embedded-contact--with-content-below'
|
||||
: null
|
||||
)}
|
||||
role="button"
|
||||
onClick={onClick}
|
||||
onClick={(event: React.MouseEvent) => {
|
||||
if (onClick) {
|
||||
event.stopPropagation();
|
||||
event.preventDefault();
|
||||
|
||||
onClick();
|
||||
}
|
||||
}}
|
||||
>
|
||||
{renderAvatar({ contact, i18n, size: 52, direction })}
|
||||
<div className="module-embedded-contact__text-container">
|
||||
{renderName({ contact, isIncoming, module })}
|
||||
{renderContactShorthand({ contact, isIncoming, module })}
|
||||
</div>
|
||||
</div>
|
||||
</button>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue