Linkify topics in channel joining modal

This commit is contained in:
Ken-Håvard Lieng 2020-04-24 02:37:56 +02:00
parent 77543e3aed
commit 4010132884
2 changed files with 87 additions and 86 deletions

File diff suppressed because one or more lines are too long

View File

@ -5,6 +5,7 @@ import Button from 'components/ui/Button';
import { join } from 'state/channels';
import { select } from 'state/tab';
import { searchChannels } from 'state/channelSearch';
import { linkify } from 'utils';
const Channel = memo(({ server, name, topic, userCount, joined, ...props }) => {
const handleJoinClick = useCallback(() => props.join([name], server), []);
@ -31,7 +32,7 @@ const Channel = memo(({ server, name, topic, userCount, joined, ...props }) => {
</Button>
)}
</div>
<p className="modal-channel-topic">{topic}</p>
<p className="modal-channel-topic">{linkify(topic)}</p>
</div>
);
});