Init CallLinkDetails view in calls tab

This commit is contained in:
Jamie Kyle 2024-05-22 09:24:27 -07:00 committed by GitHub
parent e9b661873b
commit 19083cadf7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
35 changed files with 665 additions and 222 deletions

View file

@ -28,6 +28,8 @@ import { usePrevious } from '../hooks/usePrevious';
import { arrow } from '../util/keyboard';
import { drop } from '../util/drop';
import { isCmdOrCtrl } from '../hooks/useKeyboardShortcuts';
import type { ForwardMessagesPayload } from '../state/ducks/globalModals';
import { ForwardMessagesModalType } from './ForwardMessagesModal';
export type PropsType = {
children?: ReactNode;
@ -39,7 +41,7 @@ export type PropsType = {
playbackDisabled: boolean;
saveAttachment: SaveAttachmentActionCreatorType;
selectedIndex: number;
toggleForwardMessagesModal: (messageIds: ReadonlyArray<string>) => unknown;
toggleForwardMessagesModal: (payload: ForwardMessagesPayload) => unknown;
onMediaPlaybackStart: () => void;
onNextAttachment: () => void;
onPrevAttachment: () => void;
@ -195,7 +197,10 @@ export function Lightbox({
closeLightbox();
const mediaItem = media[selectedIndex];
toggleForwardMessagesModal([mediaItem.message.id]);
toggleForwardMessagesModal({
type: ForwardMessagesModalType.Forward,
messageIds: [mediaItem.message.id],
});
};
const onKeyDown = useCallback(