mirror of
https://github.com/revoltchat/revite.git
synced 2024-11-29 10:20:59 -05:00
add proper placeholder for invalid invite
This commit is contained in:
parent
f9bb332605
commit
a10e5100d3
1 changed files with 15 additions and 6 deletions
|
@ -74,13 +74,22 @@ export default function EmbedInvite(props: Props) {
|
||||||
}, [client, code, invite, status]);
|
}, [client, code, invite, status]);
|
||||||
|
|
||||||
if (typeof invite === "undefined") {
|
if (typeof invite === "undefined") {
|
||||||
return <EmbedInviteBase>
|
return error ? (
|
||||||
{error ? (
|
<EmbedInviteBase>
|
||||||
<Overline type="error" error={error} />
|
<ServerIcon
|
||||||
) : (
|
size={55}
|
||||||
<Preloader type="ring" />
|
/>
|
||||||
)}
|
<EmbedInviteDetails>
|
||||||
|
<EmbedInviteName>
|
||||||
|
Invalid invite!
|
||||||
|
</EmbedInviteName>
|
||||||
|
</EmbedInviteDetails>
|
||||||
</EmbedInviteBase>
|
</EmbedInviteBase>
|
||||||
|
) : (
|
||||||
|
<EmbedInviteBase>
|
||||||
|
<Preloader type="ring" />
|
||||||
|
</EmbedInviteBase>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
return <EmbedInviteBase>
|
return <EmbedInviteBase>
|
||||||
|
|
Loading…
Reference in a new issue