-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove threads buttons #478
Merged
aulamber
merged 4 commits into
upgrade/element-web-v1.11.25
from
upgrade/element-web-v1.11.25-remove-threads-buttons
Mar 22, 2023
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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
72 changes: 72 additions & 0 deletions
72
patches/remove-thread-buttons/matrix-react-sdk+3.68.0.patch
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,72 @@ | ||
diff --git a/node_modules/matrix-react-sdk/src/components/views/context_menus/MessageContextMenu.tsx b/node_modules/matrix-react-sdk/src/components/views/context_menus/MessageContextMenu.tsx | ||
index ad56409..f9591dc 100644 | ||
--- a/node_modules/matrix-react-sdk/src/components/views/context_menus/MessageContextMenu.tsx | ||
+++ b/node_modules/matrix-react-sdk/src/components/views/context_menus/MessageContextMenu.tsx | ||
@@ -678,7 +678,9 @@ export default class MessageContextMenu extends React.Component<IProps, IState> | ||
<IconizedContextMenuOptionList> | ||
{reactButton} | ||
{replyButton} | ||
+ {/* :TCHAP: Remove Reply In Thread Button | ||
{replyInThreadButton} | ||
+ end :TCHAP: */} | ||
{editButton} | ||
</IconizedContextMenuOptionList> | ||
); | ||
diff --git a/node_modules/matrix-react-sdk/src/components/views/messages/MessageActionBar.tsx b/node_modules/matrix-react-sdk/src/components/views/messages/MessageActionBar.tsx | ||
index 1a7d773..4e8f18f 100644 | ||
--- a/node_modules/matrix-react-sdk/src/components/views/messages/MessageActionBar.tsx | ||
+++ b/node_modules/matrix-react-sdk/src/components/views/messages/MessageActionBar.tsx | ||
@@ -367,18 +367,21 @@ export default class MessageActionBar extends React.PureComponent<IMessageAction | ||
private readonly forbiddenThreadHeadMsgType = [MsgType.KeyVerificationRequest]; | ||
|
||
private get showReplyInThreadAction(): boolean { | ||
- const inNotThreadTimeline = this.context.timelineRenderingType !== TimelineRenderingType.Thread; | ||
- | ||
- const isAllowedMessageType = | ||
- !this.forbiddenThreadHeadMsgType.includes(this.props.mxEvent.getContent().msgtype as MsgType) && | ||
- /** forbid threads from live location shares | ||
- * until cross-platform support | ||
- * (PSF-1041) | ||
- */ | ||
- !M_BEACON_INFO.matches(this.props.mxEvent.getType()) && | ||
- !(this.props.mxEvent.getType() === VoiceBroadcastInfoEventType); | ||
- | ||
- return inNotThreadTimeline && isAllowedMessageType; | ||
+ // :TCHAP: hide thread button | ||
+ return false; | ||
+ // const inNotThreadTimeline = this.context.timelineRenderingType !== TimelineRenderingType.Thread; | ||
+ | ||
+ // const isAllowedMessageType = | ||
+ // !this.forbiddenThreadHeadMsgType.includes(this.props.mxEvent.getContent().msgtype as MsgType) && | ||
+ // /** forbid threads from live location shares | ||
+ // * until cross-platform support | ||
+ // * (PSF-1041) | ||
+ // */ | ||
+ // !M_BEACON_INFO.matches(this.props.mxEvent.getType()) && | ||
+ // !(this.props.mxEvent.getType() === VoiceBroadcastInfoEventType); | ||
+ | ||
+ // return inNotThreadTimeline && isAllowedMessageType; | ||
+ // end :TCHAP | ||
} | ||
|
||
/** | ||
diff --git a/node_modules/matrix-react-sdk/src/components/views/right_panel/RoomHeaderButtons.tsx b/node_modules/matrix-react-sdk/src/components/views/right_panel/RoomHeaderButtons.tsx | ||
index 4d7e873..1a6e2f6 100644 | ||
--- a/node_modules/matrix-react-sdk/src/components/views/right_panel/RoomHeaderButtons.tsx | ||
+++ b/node_modules/matrix-react-sdk/src/components/views/right_panel/RoomHeaderButtons.tsx | ||
@@ -292,6 +292,7 @@ export default class RoomHeaderButtons extends HeaderButtons<IProps> { | ||
onClick={this.onTimelineCardClicked} | ||
/>, | ||
); | ||
+ /* :TCHAP: Remove Thread from Header Buttons | ||
rightPanelPhaseButtons.set( | ||
RightPanelPhases.ThreadPanel, | ||
<HeaderButton | ||
@@ -306,6 +307,7 @@ export default class RoomHeaderButtons extends HeaderButtons<IProps> { | ||
<UnreadIndicator color={this.state.threadNotificationColor} /> | ||
</HeaderButton>, | ||
); | ||
+ end :TCHAP: */ | ||
rightPanelPhaseButtons.set( | ||
RightPanelPhases.NotificationPanel, | ||
<HeaderButton |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aulamber c'est possible d'avoir une capture d'écran de ce changement ?