Fix space mention (#1439)
* open space on space mention click * fix styles * fix message options sticks * revert last changes
This commit is contained in:
parent
1bdb7f4e3a
commit
13573f4b3f
2 changed files with 9 additions and 3 deletions
|
@ -86,7 +86,12 @@ import {
|
||||||
} from '../../utils/room';
|
} from '../../utils/room';
|
||||||
import { useSetting } from '../../state/hooks/settings';
|
import { useSetting } from '../../state/hooks/settings';
|
||||||
import { settingsAtom } from '../../state/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 { useForceUpdate } from '../../hooks/useForceUpdate';
|
||||||
import { parseGeoUri, scaleYDimension } from '../../utils/common';
|
import { parseGeoUri, scaleYDimension } from '../../utils/common';
|
||||||
import { useMatrixEventRenderer } from '../../hooks/useMatrixEventRenderer';
|
import { useMatrixEventRenderer } from '../../hooks/useMatrixEventRenderer';
|
||||||
|
@ -536,7 +541,8 @@ export function RoomTimeline({ room, eventId, roomInputRef, editor }: RoomTimeli
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (isRoomId(mentionId) && mx.getRoom(mentionId)) {
|
if (isRoomId(mentionId) && mx.getRoom(mentionId)) {
|
||||||
selectRoom(mentionId);
|
if (mx.getRoom(mentionId)?.isSpaceRoom()) selectSpace(mentionId);
|
||||||
|
else selectRoom(mentionId);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
openJoinAlias(mentionId);
|
openJoinAlias(mentionId);
|
||||||
|
|
|
@ -13,7 +13,7 @@ const SlideUpAnime = keyframes({
|
||||||
export const RoomViewTyping = style([
|
export const RoomViewTyping = style([
|
||||||
DefaultReset,
|
DefaultReset,
|
||||||
{
|
{
|
||||||
padding: `${config.space.S100} ${config.space.S500}`,
|
padding: `0 ${config.space.S500}`,
|
||||||
width: '100%',
|
width: '100%',
|
||||||
backgroundColor: color.Surface.Container,
|
backgroundColor: color.Surface.Container,
|
||||||
color: color.Surface.OnContainer,
|
color: color.Surface.OnContainer,
|
||||||
|
|
Loading…
Reference in a new issue