fix: resolved missing selected conversation hooks imports

pull/2861/head
William Grant 2 years ago
parent 41af1e7865
commit 5285d4240a

@ -16,8 +16,8 @@ import {
getOldBottomMessageId,
getOldTopMessageId,
getSortedMessagesTypesOfSelectedConversation,
useSelectedConversationKey,
} from '../../state/selectors/conversations';
import { useSelectedConversationKey } from '../../state/selectors/selectedConversation';
import { MessageDateBreak } from './message/message-item/DateBreak';
import { GroupInvitation } from './message/message-item/GroupInvitation';
import { GroupUpdateMessage } from './message/message-item/GroupUpdateMessage';

@ -19,9 +19,9 @@ import { StateType } from '../../state/reducer';
import {
getQuotedMessageToAnimate,
getSelectedConversation,
getSelectedConversationKey,
getSortedMessagesOfSelectedConversation,
} from '../../state/selectors/conversations';
import { getSelectedConversationKey } from '../../state/selectors/selectedConversation';
import { ConversationMessageRequestButtons } from './MessageRequestButtons';
import { SessionMessagesList } from './SessionMessagesList';
import { TypingBubble } from './TypingBubble';

@ -6,7 +6,7 @@ import {
removeAllStagedAttachmentsInConversation,
removeStagedAttachmentInConversation,
} from '../../state/ducks/stagedAttachments';
import { useSelectedConversationKey } from '../../state/selectors/conversations';
import { useSelectedConversationKey } from '../../state/selectors/selectedConversation';
import {
AttachmentType,
areAllAttachmentsVisual,

@ -3,13 +3,15 @@ import { useSelector } from 'react-redux';
import styled from 'styled-components';
import { useIsIncomingRequest } from '../../hooks/useParamSelector';
import {
getSelectedCanWrite,
getSelectedHasMessages,
hasSelectedConversationIncomingMessages,
} from '../../state/selectors/conversations';
import {
getSelectedCanWrite,
useSelectedConversationKey,
useSelectedIsNoteToSelf,
useSelectedNicknameOrProfileNameOrShortenedPubkey,
} from '../../state/selectors/conversations';
} from '../../state/selectors/selectedConversation';
import { LocalizerKeys } from '../../types/LocalizerKeys';
import { SessionHtmlRenderer } from '../basic/SessionHTMLRenderer';

@ -14,7 +14,7 @@ import {
import {
useSelectedIsPublic,
useSelectedWeAreModerator,
} from '../../state/selectors/conversations';
} from '../../state/selectors/selectedConversation';
import { SortedReactionList } from '../../types/Reaction';
import { nativeEmojiData } from '../../util/emoji';
import { Reactions } from '../../util/reactions';

@ -19,7 +19,7 @@ import {
useMentionedUs,
} from '../../../hooks/useParamSelector';
import { isSearching } from '../../../state/selectors/search';
import { useSelectedConversationKey } from '../../../state/selectors/conversations';
import { useSelectedConversationKey } from '../../../state/selectors/selectedConversation';
import { MemoConversationListItemContextMenu } from '../../menu/ConversationListItemContextMenu';
import { ContextConversationProvider, useConvoIdFromContext } from './ConvoIdContext';
import { ConversationListItemHeaderItem } from './HeaderItem';

@ -7,10 +7,8 @@ import { declineConversationWithoutConfirm } from '../../../interactions/convers
import { forceSyncConfigurationNowIfNeeded } from '../../../session/utils/sync/syncUtils';
import { updateConfirmModal } from '../../../state/ducks/modalDialog';
import { resetOverlayMode } from '../../../state/ducks/section';
import {
getConversationRequestsIds,
useSelectedConversationKey,
} from '../../../state/selectors/conversations';
import { getConversationRequestsIds } from '../../../state/selectors/conversations';
import { useSelectedConversationKey } from '../../../state/selectors/selectedConversation';
import { SessionButton, SessionButtonColor } from '../../basic/SessionButton';
import { SpacerLG } from '../../basic/Text';
import { ConversationListItem } from '../conversation-list-item/ConversationListItem';

@ -5,7 +5,7 @@ import useKey from 'react-use/lib/useKey';
import { Lightbox } from './Lightbox';
import { showLightBox } from '../../state/ducks/conversations';
import { useSelectedConversationKey } from '../../state/selectors/conversations';
import { useSelectedConversationKey } from '../../state/selectors/selectedConversation';
import { MIME } from '../../types';
import { AttachmentTypeWithPath } from '../../types/Attachment';
import { saveAttachmentToDisk } from '../../util/attachmentsUtil';

@ -130,7 +130,7 @@ const DisappearingMessageMenuItem = (): JSX.Element | null => {
key={item.value}
onClick={() => {
// TODO Confirm that this works?
void setDisappearingMessagesByConvoId(selectedConvoId, item.value);
void setDisappearingMessagesByConvoId(selectedConvoId, item.name, item.value);
}}
>
{item.name}

@ -52,7 +52,7 @@ import { getIsMessageSection } from '../../state/selectors/section';
import { LocalizerKeys } from '../../types/LocalizerKeys';
import { SessionButtonColor } from '../basic/SessionButton';
import { useConvoIdFromContext } from '../leftpane/conversation-list-item/ConvoIdContext';
import { useSelectedConversationKey } from '../../state/selectors/conversations';
import { useSelectedConversationKey } from '../../state/selectors/selectedConversation';
/** Menu items standardized */

@ -9,11 +9,11 @@ import { CONVERSATION } from '../session/constants';
import { PubKey } from '../session/types';
import { UserUtils } from '../session/utils';
import { StateType } from '../state/reducer';
import { getMessageReactsProps } from '../state/selectors/conversations';
import {
getMessageExpirationProps,
getMessageReactsProps,
isPrivateAndFriend,
} from '../state/selectors/conversations';
} from '../state/selectors/selectedConversation';
export function useAvatarPath(convoId: string | undefined) {
const convoProps = useConversationPropsById(convoId);

@ -10,7 +10,7 @@ import {
removeVideoEventsListener,
} from '../session/utils/calling/CallManager';
import { getCallIsInFullScreen, getHasOngoingCallWithPubkey } from '../state/selectors/call';
import { useSelectedConversationKey } from '../state/selectors/conversations';
import { useSelectedConversationKey } from '../state/selectors/selectedConversation';
export function useVideoCallEventsListener(uniqueId: string, onSame: boolean) {
const selectedConversationKey = useSelectedConversationKey();

@ -2,7 +2,8 @@ import { createSelector } from '@reduxjs/toolkit';
import { CallStateType, CallStatusEnum } from '../ducks/call';
import { ConversationsStateType, ReduxConversationType } from '../ducks/conversations';
import { StateType } from '../reducer';
import { getConversations, getSelectedConversationKey } from './conversations';
import { getConversations } from './conversations';
import { getSelectedConversationKey } from './selectedConversation';
const getCallState = (state: StateType): CallStateType => state.call;

@ -2,7 +2,7 @@ import { createSelector } from '@reduxjs/toolkit';
import { StagedAttachmentType } from '../../components/conversation/composition/CompositionBox';
import { StagedAttachmentsStateType } from '../ducks/stagedAttachments';
import { StateType } from '../reducer';
import { getSelectedConversationKey } from './conversations';
import { getSelectedConversationKey } from './selectedConversation';
export const getStagedAttachmentsState = (state: StateType): StagedAttachmentsStateType =>
state.stagedAttachments;

@ -7,12 +7,12 @@ import {
getIsSelectedConvoInitialLoadingInProgress,
getLightBoxOptions,
getSelectedConversation,
getSelectedConversationKey,
getSelectedMessageIds,
getSortedMessagesOfSelectedConversation,
isMessageDetailView,
isRightPanelShowing,
} from '../selectors/conversations';
import { getSelectedConversationKey } from '../selectors/selectedConversation';
import { getStagedAttachmentsForCurrentConversation } from '../selectors/stagedAttachments';
import { getTheme } from '../selectors/theme';
import { getOurNumber } from '../selectors/user';

Loading…
Cancel
Save