Caption editor: add keyboard interaction, disable for single img

This commit is contained in:
Scott Nonnenberg 2019-01-11 16:01:11 -08:00
parent b08c10a547
commit 52d3138958
2 changed files with 48 additions and 2 deletions

View file

@ -68,7 +68,9 @@ export class AttachmentList extends React.Component<Props> {
width={IMAGE_WIDTH}
url={getUrl(attachment)}
closeButton={true}
onClick={onClickAttachment}
onClick={
attachments.length > 1 ? onClickAttachment : undefined
}
onClickClose={onCloseAttachment}
/>
);