@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414limitations under the License.
1515*/
1616
17- import React , { useContext , useEffect , useState } from "react" ;
17+ import React , { ComponentProps , useContext , useEffect , useState } from "react" ;
1818import { Room } from "matrix-js-sdk/src/models/room" ;
1919import { EventType } from "matrix-js-sdk/src/@types/event" ;
2020
@@ -41,7 +41,6 @@ import ErrorDialog from "../dialogs/ErrorDialog";
4141import { showCommunityInviteDialog } from "../../../RoomInvite" ;
4242import { useDispatcher } from "../../../hooks/useDispatcher" ;
4343import InlineSpinner from "../elements/InlineSpinner" ;
44- import TooltipButton from "../elements/TooltipButton" ;
4544import MatrixClientContext from "../../../contexts/MatrixClientContext" ;
4645import RoomListStore , { LISTS_UPDATE_EVENT } from "../../../stores/room-list/RoomListStore" ;
4746import {
@@ -51,6 +50,7 @@ import {
5150 UPDATE_HOME_BEHAVIOUR ,
5251 UPDATE_SELECTED_SPACE ,
5352} from "../../../stores/spaces" ;
53+ import TooltipTarget from "../elements/TooltipTarget" ;
5454
5555const contextMenuBelow = ( elementRect : DOMRect ) => {
5656 // align the context menu's icons with the icon which opened the context menu
@@ -60,7 +60,7 @@ const contextMenuBelow = (elementRect: DOMRect) => {
6060 return { left, top, chevronFace } ;
6161} ;
6262
63- const PrototypeCommunityContextMenu = ( props ) => {
63+ const PrototypeCommunityContextMenu = ( props : ComponentProps < typeof SpaceContextMenu > ) => {
6464 const communityId = CommunityPrototypeStore . instance . getSelectedCommunityId ( ) ;
6565
6666 let settingsOption ;
@@ -327,14 +327,13 @@ const RoomListHeader = ({ spacePanelDisabled, onVisibilityChange }: IProps) => {
327327 title = getMetaSpaceName ( spaceKey as MetaSpace , allRoomsInHome ) ;
328328 }
329329
330- let pendingRoomJoinSpinner ;
330+ let pendingRoomJoinSpinner : JSX . Element ;
331331 if ( joiningRooms . size ) {
332- pendingRoomJoinSpinner = < InlineSpinner >
333- < TooltipButton helpText = { _t (
334- "Currently joining %(count)s rooms" ,
335- { count : joiningRooms . size } ,
336- ) } />
337- </ InlineSpinner > ;
332+ pendingRoomJoinSpinner = < TooltipTarget
333+ label = { _t ( "Currently joining %(count)s rooms" , { count : joiningRooms . size } ) }
334+ >
335+ < InlineSpinner />
336+ </ TooltipTarget > ;
338337 }
339338
340339 let contextMenuButton : JSX . Element = < div className = "mx_RoomListHeader_contextLessTitle" > { title } </ div > ;
0 commit comments