This repository has been archived by the owner on Sep 11, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 831
Make widgets not reload (persistent) between center and top container #7575
Merged
Merged
Changes from 9 commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
518f6d2
make widgets persistent between center and top container
toger5 0afc987
linter
toger5 e1613c4
sgWidget?.stop
toger5 5a42bb6
remove unecassary comments
toger5 c4dab35
more unecassary if's
toger5 f136cc3
rename start/stop in StopGapWidget
toger5 5e0187e
remove unecassary logic
toger5 4c2946c
fix emission on dispatch!! This is bad (for widgets at least)
toger5 16ed299
remove MEMBER_INFO_PHASES
toger5 686a6c3
Apply suggestions from code review
jryans 947aba1
Merge branch 'develop' into toger5/persistentElement_maxWidget
jryans 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -189,7 +189,7 @@ export default class AppsDrawer extends React.Component<IProps, IState> { | |
private onAction = (action: ActionPayload): void => { | ||
const hideWidgetKey = this.props.room.roomId + '_hide_widget_drawer'; | ||
switch (action.action) { | ||
case 'appsDrawer': | ||
case "appsDrawer": | ||
// Note: these booleans are awkward because localstorage is fundamentally | ||
// string-based. We also do exact equality on the strings later on. | ||
if (action.show) { | ||
|
@@ -279,7 +279,7 @@ export default class AppsDrawer extends React.Component<IProps, IState> { | |
drawer = <PersistentVResizer | ||
room={this.props.room} | ||
minHeight={100} | ||
maxHeight={(this.props.maxHeight || !widgetIsMaxmised) ? this.props.maxHeight - 50 : undefined} | ||
maxHeight={this.props.maxHeight - 50} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. all changes to this file are unrelated. If you want me to I can make a different pr. It was just super convinient and simple to include them right after I found them without switching branches. |
||
handleClass="mx_AppsContainer_resizerHandle" | ||
handleWrapperClass="mx_AppsContainer_resizerHandleContainer" | ||
className="mx_AppsContainer_resizer" | ||
|
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
Oops, something went wrong.
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.
this is the main change that fixes the issue. Instead of destroying it here we destroy it if the widget is not visible on screen anymore of if we switch room.
(this pr now fixes other bugs so i though it would be good to highlight this with a comment)