diff --git a/src/app/organisms/room/JitsiRoom.jsx b/src/app/organisms/room/JitsiRoom.jsx index 43b511b3..3a10bbb4 100644 --- a/src/app/organisms/room/JitsiRoom.jsx +++ b/src/app/organisms/room/JitsiRoom.jsx @@ -12,7 +12,7 @@ import Button from '../../atoms/button/Button'; const TOPIC_JITSI_CALL = 'd38dd491fefa1cfffc27f9c57f2bdb4a' -function JitsiRoom() { +function JitsiRoom({ setIsJitsiRoom }) { const [jitsiCallId, setJitsiCallId] = useState(null); const [roomInfo, setRoomInfo] = useState({ @@ -47,6 +47,8 @@ function JitsiRoom() { }); } } + + setIsJitsiRoom(topic === TOPIC_JITSI_CALL) }; navigation.on(cons.events.navigation.ROOM_SELECTED, handleRoomSelected); diff --git a/src/app/organisms/room/Room.jsx b/src/app/organisms/room/Room.jsx index b4c26dd7..c9d5223e 100644 --- a/src/app/organisms/room/Room.jsx +++ b/src/app/organisms/room/Room.jsx @@ -13,7 +13,7 @@ import RoomView from './RoomView'; import RoomSettings from './RoomSettings'; import PeopleDrawer from './PeopleDrawer'; -function Room() { +function Room({ isJitsiRoom }) { const [roomInfo, setRoomInfo] = useState({ roomTimeline: null, eventId: null, @@ -60,10 +60,7 @@ function Room() { return ; } - const isJitsiChannel = - roomTimeline.room.currentState.getStateEvents('m.room.topic')[0]?.getContent().topic === - 'd38dd491fefa1cfffc27f9c57f2bdb4a'; - if (isJitsiChannel) { + if (isJitsiRoom) { return null; } diff --git a/src/app/templates/client/Client.jsx b/src/app/templates/client/Client.jsx index d545be86..72d1988e 100644 --- a/src/app/templates/client/Client.jsx +++ b/src/app/templates/client/Client.jsx @@ -27,6 +27,7 @@ function Client() { const [isLoading, changeLoading] = useState(true); const [loadingMsg, setLoadingMsg] = useState('Heating up'); const [dragCounter, setDragCounter] = useState(0); + const [isJitsiRoom, setIsJitsiRoom] = useState(false); const classNameHidden = 'client__item-hidden'; const navWrapperRef = useRef(null); @@ -161,6 +162,9 @@ function Client() { initMatrix.roomsInput.emit(cons.events.roomsInput.ATTACHMENT_SET, file); } + const JITSI_ROOM_CLASS = 'jitsi_room__wrapper' + const ROOM_CLASS = `room__wrapper ${classNameHidden}` + return (
-
- -
-
- +
+ +
+
+
diff --git a/src/app/templates/client/Client.scss b/src/app/templates/client/Client.scss index 7579b4d4..e9c6ff49 100644 --- a/src/app/templates/client/Client.scss +++ b/src/app/templates/client/Client.scss @@ -51,6 +51,10 @@ } } +.hidden { + display: none; +} + .loading-display { position: absolute; top: 0;