Merge pull request #140 from matrix-org/fractal-description

Update fractal description
This commit is contained in:
Jorik Schellekens 2020-09-23 17:02:45 +01:00 committed by GitHub
commit d69f9b0ab4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 24 additions and 16 deletions

View file

@ -37,9 +37,14 @@ const Fractal: TextClient = {
case LinkKind.Alias:
case LinkKind.RoomId:
case LinkKind.UserId:
return <span>Click the '+' button in the top right</span>;
return (
<span>
Click the '+' button in the top right and paste the
identifier
</span>
);
default:
return <span>Weechat doesn't support this kind of link</span>;
return <span>Fractal doesn't support this kind of link</span>;
}
},
copyString: (link) => {
@ -63,7 +68,7 @@ const Fractal: TextClient = {
}
},
description: 'Command-line Matrix interface using Weechat',
description: 'Fractal is a Matrix Client written in Rust',
};
export default Fractal;

View file

@ -39,19 +39,22 @@ const ClientTile: React.FC<IProps> = ({ client, link }: IProps) => {
clientTileLink: client.kind === ClientKind.LINKED_CLIENT,
});
const inviteButton =
client.kind === ClientKind.LINKED_CLIENT ? (
<Button>Accept invite</Button>
) : (
let inviteButton: JSX.Element = <></>;
if (client.kind === ClientKind.LINKED_CLIENT) {
inviteButton = <Button>Accept invite</Button>;
} else {
const copyString = client.copyString(link);
if (copyString !== '') {
inviteButton = (
<Button
onClick={() =>
navigator.clipboard.writeText(client.copyString(link))
}
onClick={() => navigator.clipboard.writeText(copyString)}
flashChildren="Invite copied"
>
Copy invite
</Button>
);
}
}
let clientTile = (
<Tile className={className}>