Migrate LightboxGallery to Storybook

This commit is contained in:
Chris Svenningsen 2020-08-21 15:06:33 -07:00 committed by Josh Perez
parent 4b0c206128
commit 84fee07a72
3 changed files with 92 additions and 72 deletions

View file

@ -19,7 +19,7 @@ export interface MediaItemType {
message: Message;
}
interface Props {
export interface Props {
close: () => void;
i18n: LocalizerType;
media: Array<MediaItemType>;
@ -60,7 +60,8 @@ export class LightboxGallery extends React.Component<Props, State> {
selectedIndex > firstIndex ? this.handlePrevious : undefined;
const onNext = selectedIndex < lastIndex ? this.handleNext : undefined;
const objectURL = selectedMedia.objectURL || 'images/alert-outline.svg';
const objectURL =
selectedMedia.objectURL || 'images/full-screen-flow/alert-outline.svg';
const { attachment } = selectedMedia;
const saveCallback = onSave ? this.handleSave : undefined;