Report the activity bar against the message in the viewport.
Trigger cinny-mobile / dispatch (push) Successful in 1s
Trigger cinny-mobile / dispatch (push) Successful in 1s
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import React, { useCallback, useRef } from 'react';
|
||||
import React, { useCallback, useRef, useState } from 'react';
|
||||
import { Box, Text, config } from 'folds';
|
||||
import { EventType, Room } from 'matrix-js-sdk';
|
||||
import { ReactEditor } from 'slate-react';
|
||||
@@ -65,6 +65,7 @@ export function RoomView({ room, eventId }: { room: Room; eventId?: string }) {
|
||||
const roomViewRef = useRef<HTMLDivElement>(null);
|
||||
|
||||
const [hideActivity] = useSetting(settingsAtom, 'hideActivity');
|
||||
const [viewportEventId, setViewportEventId] = useState<string>();
|
||||
|
||||
const { roomId } = room;
|
||||
const editor = useEditor();
|
||||
@@ -117,10 +118,11 @@ export function RoomView({ room, eventId }: { room: Room; eventId?: string }) {
|
||||
eventId={eventId}
|
||||
roomInputRef={roomInputRef}
|
||||
editor={editor}
|
||||
onViewportAnchorChange={setViewportEventId}
|
||||
/>
|
||||
<div className={roomViewCss.RoomViewBottomFloat}>
|
||||
<RoomViewTyping room={room} />
|
||||
{!hideActivity && <RoomViewFollowing room={room} />}
|
||||
{!hideActivity && <RoomViewFollowing room={room} eventId={viewportEventId} />}
|
||||
</div>
|
||||
</Box>
|
||||
<Box shrink="No" direction="Column">
|
||||
|
||||
Reference in New Issue
Block a user