Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Fix the sticker picker (#7692) (#7695)
Browse files Browse the repository at this point in the history
* Fix the sticker picker

Don't stop user widgets on room change: they're not room-specific.

Fixes element-hq/element-web#20797

* Use 'userWidget' prop rather than roomId being defined
  • Loading branch information
dbkr authored Feb 1, 2022
1 parent 6c16a2c commit 806cd26
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/components/views/elements/AppTile.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,8 @@ export default class AppTile extends React.Component<IProps, IState> {
if (this.props.room.roomId == RoomViewStore.getRoomId()) return;
const app = this.props.app;
const isActiveWidget = ActiveWidgetStore.instance.getWidgetPersistence(app.id);
if (!isActiveWidget) {
// Stop the widget if it's not the active (persistent) widget and it's not a user widget
if (!isActiveWidget && !this.props.userWidget) {
ActiveWidgetStore.instance.destroyPersistentWidget(app.id);
PersistedElement.destroyElement(this.persistKey);
this.sgWidget?.stopMessaging();
Expand Down

0 comments on commit 806cd26

Please sign in to comment.