Merge pull request #59 from superhero-com/features/sync-code

fix: invite dialog
pull/27073/head
Badi Ifaoui 2024-02-15 13:42:46 +01:00 committed by GitHub
commit 1b560bb78b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 1 additions and 18 deletions

View File

@ -1,11 +0,0 @@
name: Pull Request
on:
pull_request_target:
types: [opened, edited, labeled, unlabeled, synchronize]
merge_group:
types: [checks_requested]
jobs:
action:
uses: matrix-org/matrix-js-sdk/.github/workflows/pull_request.yaml@develop
secrets:
ELEMENT_BOT_TOKEN: ${{ secrets.ELEMENT_BOT_TOKEN }}

View File

@ -27,7 +27,6 @@ import { _t, _td } from "matrix-react-sdk/src/languageHandler";
import { MatrixClientPeg } from "matrix-react-sdk/src/MatrixClientPeg";
import { makeRoomPermalink, makeUserPermalink } from "matrix-react-sdk/src/utils/permalinks/Permalinks";
import DMRoomMap from "matrix-react-sdk/src/utils/DMRoomMap";
import SdkConfig from "matrix-react-sdk/src/SdkConfig";
import * as Email from "matrix-react-sdk/src/email";
import {
getDefaultIdentityServerUrl,
@ -379,9 +378,6 @@ export default class InviteDialog extends React.PureComponent<Props, IInviteDial
this.profilesStore = SdkContextClass.instance.userProfilesStore;
const excludedIds = new Set([MatrixClientPeg.safeGet().getUserId()!]);
const welcomeUserId = SdkConfig.get("welcome_user_id");
if (welcomeUserId) excludedIds.add(welcomeUserId);
if (isRoomInvite(props)) {
const room = MatrixClientPeg.safeGet().getRoom(props.roomId);
const isFederated = room?.currentState.getStateEvents(EventType.RoomCreate, "")?.getContent()["m.federate"];
@ -1346,9 +1342,7 @@ export default class InviteDialog extends React.PureComponent<Props, IInviteDial
footer = (
<div className="mx_InviteDialog_footer">
<h3>{_t("invite|send_link_prompt")}</h3>
<CopyableText
getTextToCopy={(): string => makeUserPermalink(MatrixClientPeg.safeGet().getSafeUserId())}
>
<CopyableText getTextToCopy={() => makeUserPermalink(MatrixClientPeg.safeGet().getSafeUserId())}>
<a className="mx_InviteDialog_footer_link" href={link} onClick={this.onLinkClick}>
{link}
</a>