Upgrade Prettier to 2.4.1

This commit is contained in:
Evan Hahn 2021-11-11 16:43:05 -06:00 committed by GitHub
parent f204784afe
commit 5619eeca83
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
176 changed files with 1961 additions and 2465 deletions

View file

@ -22,14 +22,12 @@ import type { SafetyNumberProps } from '../../components/SafetyNumberChangeDialo
const mapStateToProps = (state: StateType) => {
return {
...state.app,
conversationsStoppingMessageSendBecauseOfVerification: getConversationsStoppingMessageSendBecauseOfVerification(
state
),
conversationsStoppingMessageSendBecauseOfVerification:
getConversationsStoppingMessageSendBecauseOfVerification(state),
i18n: getIntl(state),
isCustomizingPreferredReactions: getIsCustomizingPreferredReactions(state),
numberOfMessagesPendingBecauseOfVerification: getNumberOfMessagesPendingBecauseOfVerification(
state
),
numberOfMessagesPendingBecauseOfVerification:
getNumberOfMessagesPendingBecauseOfVerification(state),
renderCallManager: () => <SmartCallManager />,
renderCustomizingPreferredReactionsModal: () => (
<SmartCustomizingPreferredReactionsModal />

View file

@ -44,9 +44,8 @@ function renderSafetyNumberViewer(props: SafetyNumberViewerProps): JSX.Element {
return <SmartSafetyNumberViewer {...props} />;
}
const getGroupCallVideoFrameSource = callingService.getGroupCallVideoFrameSource.bind(
callingService
);
const getGroupCallVideoFrameSource =
callingService.getGroupCallVideoFrameSource.bind(callingService);
async function notifyForCall(
title: string,

View file

@ -44,12 +44,8 @@ const mapStateToProps = (state: StateType, props: ExternalProps) => {
throw new Error(`Conversation id ${id} not found!`);
}
const {
announcementsOnly,
areWeAdmin,
draftText,
draftBodyRanges,
} = conversation;
const { announcementsOnly, areWeAdmin, draftText, draftBodyRanges } =
conversation;
const receivedPacks = getReceivedStickerPacks(state);
const installedPacks = getInstalledStickerPacks(state);
@ -125,9 +121,8 @@ const mapStateToProps = (state: StateType, props: ExternalProps) => {
conversationType: conversation.type,
isSMSOnly: Boolean(isConversationSMSOnly(conversation)),
isFetchingUUID: conversation.isFetchingUUID,
isMissingMandatoryProfileSharing: isMissingRequiredProfileSharing(
conversation
),
isMissingMandatoryProfileSharing:
isMissingRequiredProfileSharing(conversation),
// Groups
announcementsOnly,
areWeAdmin,

View file

@ -107,9 +107,8 @@ const mapStateToProps = (state: StateType, ownProps: OwnProps) => {
]),
badge: getPreferredBadgeSelector(state)(conversation.badges),
conversationTitle: state.conversations.selectedConversationTitle,
isMissingMandatoryProfileSharing: isMissingRequiredProfileSharing(
conversation
),
isMissingMandatoryProfileSharing:
isMissingRequiredProfileSharing(conversation),
isSMSOnly: isConversationSMSOnly(conversation),
i18n: getIntl(state),
showBackButton: state.conversations.selectedConversationPanelDepth > 0,

View file

@ -17,11 +17,8 @@ export type OwnProps = {
};
const mapStateToProps = (state: StateType, props: OwnProps) => {
const {
conversationId,
setDontNotifyForMentionsIfMuted,
setMuteExpiration,
} = props;
const { conversationId, setDontNotifyForMentionsIfMuted, setMuteExpiration } =
props;
const conversationSelector = getConversationByIdSelector(state);
const conversation = conversationSelector(conversationId);

View file

@ -43,11 +43,8 @@ export type PropsType = {
};
const mapStateToProps = (_state: StateType, props: PropsType) => {
const {
compositionAreaProps,
conversationHeaderProps,
timelineProps,
} = props;
const { compositionAreaProps, conversationHeaderProps, timelineProps } =
props;
return {
renderCompositionArea: () => (

View file

@ -28,9 +28,8 @@ export const SmartReactionPicker = React.forwardRef<
HTMLDivElement,
ExternalProps
>((props, ref) => {
const {
openCustomizePreferredReactionsModal,
} = usePreferredReactionsActions();
const { openCustomizePreferredReactionsModal } =
usePreferredReactionsActions();
const { onSetSkinTone } = useItemsActions();
const i18n = useSelector<StateType, LocalizerType>(getIntl);

View file

@ -177,9 +177,8 @@ const getWarning = (
switch (conversation.type) {
case 'direct':
if (!conversation.acceptedMessageRequest && !conversation.isBlocked) {
const getConversationsWithTitle = getConversationsByTitleSelector(
state
);
const getConversationsWithTitle =
getConversationsByTitleSelector(state);
const conversationsWithSameTitle = getConversationsWithTitle(
conversation.title
);
@ -221,9 +220,8 @@ const getWarning = (
type: ContactSpoofingType.MultipleGroupMembersWithSameTitle,
acknowledgedGroupNameCollisions:
conversation.acknowledgedGroupNameCollisions || {},
groupNameCollisions: dehydrateCollisionsWithConversations(
groupNameCollisions
),
groupNameCollisions:
dehydrateCollisionsWithConversations(groupNameCollisions),
};
}
@ -308,9 +306,8 @@ const mapStateToProps = (state: StateType, props: ExternalProps) => {
!conversation.acceptedMessageRequest
),
...conversationMessages,
invitedContactsForNewlyCreatedGroup: getInvitedContactsForNewlyCreatedGroup(
state
),
invitedContactsForNewlyCreatedGroup:
getInvitedContactsForNewlyCreatedGroup(state),
selectedMessageId: selectedMessage ? selectedMessage.id : undefined,
warning: getWarning(conversation, state),