Skip to content

Commit

Permalink
Fix space mention (#1439)
Browse files Browse the repository at this point in the history
* open space on space mention click

* fix styles

* fix message options sticks

* revert last changes
  • Loading branch information
ajbura authored Oct 7, 2023
1 parent 1bdb7f4 commit 13573f4
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
10 changes: 8 additions & 2 deletions src/app/organisms/room/RoomTimeline.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,12 @@ import {
} from '../../utils/room';
import { useSetting } from '../../state/hooks/settings';
import { settingsAtom } from '../../state/settings';
import { openJoinAlias, openProfileViewer, selectRoom } from '../../../client/action/navigation';
import {
openJoinAlias,
openProfileViewer,
selectRoom,
selectSpace,
} from '../../../client/action/navigation';
import { useForceUpdate } from '../../hooks/useForceUpdate';
import { parseGeoUri, scaleYDimension } from '../../utils/common';
import { useMatrixEventRenderer } from '../../hooks/useMatrixEventRenderer';
Expand Down Expand Up @@ -536,7 +541,8 @@ export function RoomTimeline({ room, eventId, roomInputRef, editor }: RoomTimeli
return;
}
if (isRoomId(mentionId) && mx.getRoom(mentionId)) {
selectRoom(mentionId);
if (mx.getRoom(mentionId)?.isSpaceRoom()) selectSpace(mentionId);
else selectRoom(mentionId);
return;
}
openJoinAlias(mentionId);
Expand Down
2 changes: 1 addition & 1 deletion src/app/organisms/room/RoomViewTyping.css.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const SlideUpAnime = keyframes({
export const RoomViewTyping = style([
DefaultReset,
{
padding: `${config.space.S100} ${config.space.S500}`,
padding: `0 ${config.space.S500}`,
width: '100%',
backgroundColor: color.Surface.Container,
color: color.Surface.OnContainer,
Expand Down

0 comments on commit 13573f4

Please sign in to comment.