-
Notifications
You must be signed in to change notification settings - Fork 11k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into fix/contacts-update-old-custom-fields
- Loading branch information
Showing
190 changed files
with
3,649 additions
and
2,003 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
"@rocket.chat/model-typings": patch | ||
--- | ||
|
||
Fixes Unit's `numDepartments` property not being updated after a department is removed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/apps-engine': patch | ||
--- | ||
|
||
Fixes the subprocess restarting routine failing to correctly restart apps in some cases |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
"@rocket.chat/i18n": patch | ||
--- | ||
|
||
Fixes the incorrect registration status shown on admin users page for federated remote users. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
"@rocket.chat/model-typings": patch | ||
--- | ||
|
||
Fixes "Average first response time" and "Best first response time" metrics being associated with the last agent who served the room (instead of the first one) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/meteor': patch | ||
--- | ||
|
||
Fixes an issue preventing the creation of normal direct message rooms due to an invalid federation configuration, allowing proper room creation under standard settings. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/meteor': patch | ||
--- | ||
|
||
Fixes an issue where room members menu doesn't display properly without enough space |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/meteor': patch | ||
--- | ||
|
||
Fixes missing images in Twitter article links to ensure proper display by relying on meta tags. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/apps-engine': patch | ||
--- | ||
|
||
Adds simple app subprocess metrics report |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
--- | ||
|
||
Fixes an issue with Federation startup where the bridge would intermittently fail to start causing error being shown "Matrix Bridge isn't running yet". |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/apps-engine': patch | ||
--- | ||
|
||
Attempts to restart an app subprocess if the spawn command fails |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
--- | ||
"@rocket.chat/i18n": patch | ||
--- | ||
|
||
Changes the wording for voice call permissions, improving consistency and clarity. | ||
|
||
- `Manage Voip Extension` -> `Manage Voice Calls` | ||
> Permission to manage voice calls and assign extensions to users | ||
- `View VoIP extension details` -> `View Voice Call Extensions` | ||
> Permission to view which user is calling and their extension info | ||
- `View User VoIP extension` -> `Allow Voice Calls` | ||
> Permission to allow users to use the voice call feature | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
--- | ||
|
||
Fixes messages not being processed for all slack servers |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
--- | ||
|
||
Allows default avatars to be generated with more than one inital (limited to first 3) when setting `Use Full Name Initials to Generate Default Avatar` is true. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/apps-engine': patch | ||
--- | ||
|
||
Fixes an issue while collecting the error message from a failed restart attempt of an app subprocess |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
--- | ||
|
||
Fixed an issue that added potencially infinite callbacks to the same event, degrading performance over time. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@rocket.chat/meteor": patch | ||
--- | ||
|
||
Fixes a behavior of the mentions parser that identified mentions inside markdown links text. Now, these components will be removed from the text before trying to parse mentions. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/meteor': patch | ||
--- | ||
|
||
Fixes special characters not being escaped on sidepanel extended view |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
"@rocket.chat/meteor": minor | ||
"@rocket.chat/core-typings": minor | ||
"@rocket.chat/rest-typings": minor | ||
--- | ||
|
||
Adds a new callout in the subscription page to inform users of subscription upgrade eligibility when applicable. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@rocket.chat/apps-engine': patch | ||
--- | ||
|
||
Prevents app:getStatus requests from timing out in some cases |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,96 +1,7 @@ | ||
import { Meteor } from 'meteor/meteor'; | ||
import { Tracker } from 'meteor/tracker'; | ||
|
||
import { AutoTranslate } from './autotranslate'; | ||
import { roomCoordinator } from '../../../../client/lib/rooms/roomCoordinator'; | ||
import { | ||
hasTranslationLanguageInAttachments, | ||
hasTranslationLanguageInMessage, | ||
} from '../../../../client/views/room/MessageList/lib/autoTranslate'; | ||
import { hasAtLeastOnePermission } from '../../../authorization/client'; | ||
import { Messages } from '../../../models/client'; | ||
import { settings } from '../../../settings/client'; | ||
import { MessageAction } from '../../../ui-utils/client/lib/MessageAction'; | ||
import { sdk } from '../../../utils/client/lib/SDKClient'; | ||
|
||
Meteor.startup(() => { | ||
AutoTranslate.init(); | ||
|
||
Tracker.autorun(() => { | ||
if (settings.get('AutoTranslate_Enabled') && hasAtLeastOnePermission(['auto-translate'])) { | ||
MessageAction.addButton({ | ||
id: 'translate', | ||
icon: 'language', | ||
label: 'Translate', | ||
context: ['message', 'message-mobile', 'threads'], | ||
type: 'interaction', | ||
action(_, { message }) { | ||
const language = AutoTranslate.getLanguage(message.rid); | ||
if (!hasTranslationLanguageInMessage(message, language) && !hasTranslationLanguageInAttachments(message.attachments, language)) { | ||
(AutoTranslate.messageIdsToWait as any)[message._id] = true; | ||
Messages.update({ _id: message._id }, { $set: { autoTranslateFetching: true } }); | ||
void sdk.call('autoTranslate.translateMessage', message, language); | ||
} | ||
const action = 'autoTranslateShowInverse' in message ? '$unset' : '$set'; | ||
Messages.update({ _id: message._id }, { [action]: { autoTranslateShowInverse: true } }); | ||
}, | ||
condition({ message, subscription, user, room }) { | ||
if (!user) { | ||
return false; | ||
} | ||
const language = subscription?.autoTranslateLanguage || AutoTranslate.getLanguage(message.rid) || ''; | ||
const isLivechatRoom = roomCoordinator.isLivechatRoom(room?.t); | ||
const isDifferentUser = message?.u && message.u._id !== user._id; | ||
const autoTranslateEnabled = subscription?.autoTranslate || isLivechatRoom; | ||
const hasLanguage = | ||
hasTranslationLanguageInMessage(message, language) || hasTranslationLanguageInAttachments(message.attachments, language); | ||
|
||
return Boolean( | ||
(message as { autoTranslateShowInverse?: boolean }).autoTranslateShowInverse || | ||
(isDifferentUser && autoTranslateEnabled && !hasLanguage), | ||
); | ||
}, | ||
order: 90, | ||
}); | ||
MessageAction.addButton({ | ||
id: 'view-original', | ||
icon: 'language', | ||
label: 'View_original', | ||
context: ['message', 'message-mobile', 'threads'], | ||
type: 'interaction', | ||
action(_, props) { | ||
const { message } = props; | ||
const language = AutoTranslate.getLanguage(message.rid); | ||
if (!hasTranslationLanguageInMessage(message, language) && !hasTranslationLanguageInAttachments(message.attachments, language)) { | ||
(AutoTranslate.messageIdsToWait as any)[message._id] = true; | ||
Messages.update({ _id: message._id }, { $set: { autoTranslateFetching: true } }); | ||
void sdk.call('autoTranslate.translateMessage', message, language); | ||
} | ||
const action = 'autoTranslateShowInverse' in message ? '$unset' : '$set'; | ||
Messages.update({ _id: message._id }, { [action]: { autoTranslateShowInverse: true } }); | ||
}, | ||
condition({ message, subscription, user, room }) { | ||
const language = subscription?.autoTranslateLanguage || AutoTranslate.getLanguage(message.rid) || ''; | ||
const isLivechatRoom = roomCoordinator.isLivechatRoom(room?.t); | ||
if (!user) { | ||
return false; | ||
} | ||
const isDifferentUser = message?.u && message.u._id !== user._id; | ||
const autoTranslateEnabled = subscription?.autoTranslate || isLivechatRoom; | ||
const hasLanguage = | ||
hasTranslationLanguageInMessage(message, language) || hasTranslationLanguageInAttachments(message.attachments, language); | ||
|
||
return Boolean( | ||
!(message as { autoTranslateShowInverse?: boolean }).autoTranslateShowInverse && | ||
isDifferentUser && | ||
autoTranslateEnabled && | ||
hasLanguage, | ||
); | ||
}, | ||
order: 90, | ||
}); | ||
} else { | ||
MessageAction.removeButton('toggle-language'); | ||
} | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
apps/meteor/app/cloud/server/functions/syncWorkspace/fetchWorkspaceSyncPayload.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
import type { Cloud, Serialized } from '@rocket.chat/core-typings'; | ||
import { serverFetch as fetch } from '@rocket.chat/server-fetch'; | ||
import { v, compile } from 'suretype'; | ||
|
||
import { CloudWorkspaceConnectionError } from '../../../../../lib/errors/CloudWorkspaceConnectionError'; | ||
import { settings } from '../../../../settings/server'; | ||
|
||
const workspaceSyncPayloadSchema = v.object({ | ||
workspaceId: v.string().required(), | ||
publicKey: v.string(), | ||
license: v.string().required(), | ||
}); | ||
|
||
const assertWorkspaceSyncPayload = compile(workspaceSyncPayloadSchema); | ||
|
||
export async function fetchWorkspaceSyncPayload({ | ||
token, | ||
data, | ||
}: { | ||
token: string; | ||
data: Cloud.WorkspaceSyncRequestPayload; | ||
}): Promise<Serialized<Cloud.WorkspaceSyncResponse>> { | ||
const workspaceRegistrationClientUri = settings.get<string>('Cloud_Workspace_Registration_Client_Uri'); | ||
const response = await fetch(`${workspaceRegistrationClientUri}/sync`, { | ||
method: 'POST', | ||
headers: { | ||
Authorization: `Bearer ${token}`, | ||
}, | ||
body: data, | ||
}); | ||
|
||
if (!response.ok) { | ||
const { error } = await response.json(); | ||
throw new CloudWorkspaceConnectionError(`Failed to connect to Rocket.Chat Cloud: ${error}`); | ||
} | ||
|
||
const payload = await response.json(); | ||
|
||
assertWorkspaceSyncPayload(payload); | ||
|
||
return payload; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.