Skip to content

Commit 3fc677f

Browse files
Merge branch 'develop' into bump-webpack
2 parents 1619cc9 + 36e90a2 commit 3fc677f

File tree

88 files changed

+1442
-1665
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+1442
-1665
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@rocket.chat/meteor': minor
3+
---
4+
5+
Includes attachments metadata in JSON export if type is file when exporting messages

.changeset/yellow-cars-change.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
'@rocket.chat/fuselage-ui-kit': patch
3+
'@rocket.chat/ui-video-conf': patch
4+
'@rocket.chat/i18n': patch
5+
'@rocket.chat/meteor': patch
6+
---
7+
8+
Fixes an issue where video conf message block wasn't considering display avatars preference

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
/apps/meteor/app/voip @RocketChat/omnichannel
2121
/apps/meteor/app/sms @RocketChat/omnichannel
2222
/apps/meteor/server @RocketChat/backend
23-
/apps/meteor/server/models @RocketChat/Architecture
23+
/packages/models @RocketChat/Architecture
2424
apps/meteor/server/startup/migrations @RocketChat/Architecture
2525
/apps/meteor/packages/rocketchat-livechat @RocketChat/omnichannel
2626
/apps/meteor/server/services/voip-asterisk @RocketChat/omnichannel

apps/meteor/app/push/server/apn.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1+
import apn from '@parse/node-apn';
12
import type { IAppsTokens, RequiredField } from '@rocket.chat/core-typings';
2-
import apn from 'apn';
33
import EJSON from 'ejson';
44

55
import type { PushOptions, PendingPushNotification } from './definition';
66
import { logger } from './logger';
77

88
let apnConnection: apn.Provider | undefined;
99

10-
declare module 'apn' {
10+
declare module '@parse/node-apn' {
1111
// eslint-disable-next-line @typescript-eslint/naming-convention
1212
interface Notification {
1313
setContentAvailable: (value: boolean | 1 | 0) => void;
@@ -72,7 +72,7 @@ export const sendAPN = ({
7272
response.failed.forEach((failure) => {
7373
logger.debug(`Got error code ${failure.status} for token ${userToken}`);
7474

75-
if (['400', '410'].includes(failure.status ?? '')) {
75+
if (['400', '410'].includes(String(failure.status))) {
7676
logger.debug(`Removing token ${userToken}`);
7777
_removeToken({
7878
apn: userToken,

apps/meteor/client/startup/index.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ import './reloadRoomAfterLogin';
2020
import './roles';
2121
import './rootUrlChange';
2222
import './routes';
23-
import './setupWizard';
2423
import './slashCommands';
2524
import './startup';
2625
import './streamMessage';

apps/meteor/client/startup/setupWizard.ts

Lines changed: 0 additions & 20 deletions
This file was deleted.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { useRole, useRouter, useSetting, useUserId } from '@rocket.chat/ui-contexts';
2+
import { useEffect } from 'react';
3+
4+
export const useRedirectToSetupWizard = (): void => {
5+
const userId = useUserId();
6+
const setupWizardState = useSetting('Show_Setup_Wizard');
7+
const router = useRouter();
8+
const isAdmin = useRole('admin');
9+
10+
const isWizardInProgress = userId && isAdmin && setupWizardState === 'in_progress';
11+
const mustRedirect = (!userId && setupWizardState === 'pending') || isWizardInProgress;
12+
useEffect(() => {
13+
if (mustRedirect) {
14+
router.navigate('/setup-wizard');
15+
}
16+
}, [mustRedirect, router]);
17+
};

apps/meteor/client/views/composer/AudioMessageRecorder/AudioMessageRecorder.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ const AudioMessageRecorder = ({ rid, chatContext, isMicrophoneDenied }: AudioMes
5151
});
5252

5353
const handleRecord = useEffectEvent(async () => {
54+
chat?.composer?.setRecordingMode(true);
55+
5456
if (recordingRoomId && recordingRoomId !== rid) {
5557
return;
5658
}
@@ -105,7 +107,7 @@ const AudioMessageRecorder = ({ rid, chatContext, isMicrophoneDenied }: AudioMes
105107
}
106108

107109
return (
108-
<Box display='flex' position='absolute' color='default' pi={4} pb={12}>
110+
<Box display='flex' position='absolute' color='default' pi={4} pb={12} role='group' aria-label={t('Audio_recorder')}>
109111
{state === 'recording' && (
110112
<>
111113
<MessageComposerAction icon='circle-cross' title={t('Cancel_recording')} onClick={handleCancelButtonClick} />

apps/meteor/client/views/room/contextualBar/ExportMessages/useDownloadExportMutation.ts

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,29 @@ import { Messages } from '../../../../../app/models/client';
88
import { downloadJsonAs } from '../../../../lib/download';
99
import { useRoom } from '../../contexts/RoomContext';
1010

11-
const messagesFields: FindOptions<IMessage> = { projection: { _id: 1, ts: 1, u: 1, msg: 1, _updatedAt: 1, tlm: 1, replies: 1, tmid: 1 } };
11+
const messagesFields: FindOptions<IMessage> = {
12+
projection: {
13+
'_id': 1,
14+
'ts': 1,
15+
'u': 1,
16+
'msg': 1,
17+
'_updatedAt': 1,
18+
'tlm': 1,
19+
'replies': 1,
20+
'tmid': 1,
21+
'attachments.ts': 1,
22+
'attachments.title': 1,
23+
'attachments.title_link': 1,
24+
'attachments.title_link_download': 1,
25+
'attachments.image_dimensions': 1,
26+
'attachments.image_preview': 1,
27+
'attachments.image_url': 1,
28+
'attachments.image_type': 1,
29+
'attachments.image_size': 1,
30+
'attachments.type': 1,
31+
'attachments.description': 1,
32+
},
33+
};
1234

1335
export const useDownloadExportMutation = () => {
1436
const { t } = useTranslation();

apps/meteor/client/views/room/contextualBar/VideoConference/VideoConfList/VideoConfListItem.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ const VideoConfListItem = ({
106106
</Avatar.Stack>
107107
<Box mis={4}>
108108
{joinedUsers.length > VIDEOCONF_STACK_MAX_USERS
109-
? t('__usersCount__member_joined', { count: joinedUsers.length - VIDEOCONF_STACK_MAX_USERS })
109+
? t('__usersCount__joined', { count: joinedUsers.length - VIDEOCONF_STACK_MAX_USERS })
110110
: t('joined')}
111111
</Box>
112112
</Box>

0 commit comments

Comments
 (0)