chore: bug fix cleanup (#4)
This commit is contained in:
@@ -82,14 +82,12 @@ const ChannelInvitesTab: React.FC<{channelId: string}> = observer(({channelId})
|
||||
</p>
|
||||
</div>
|
||||
|
||||
{!(fetchStatus === 'success' && invites && invites.length === 0) && (
|
||||
<div className={styles.buttonGroup}>
|
||||
<Button small={true} disabled={!canInvite} onClick={handleCreateInvite}>
|
||||
<Trans>Create Invite</Trans>
|
||||
</Button>
|
||||
{canManageGuild && channel?.guildId && <DisableInvitesButton guildId={channel.guildId} />}
|
||||
</div>
|
||||
)}
|
||||
<div className={styles.buttonGroup}>
|
||||
<Button small={true} disabled={!canInvite || fetchStatus === 'pending'} onClick={handleCreateInvite}>
|
||||
<Trans>Create Invite</Trans>
|
||||
</Button>
|
||||
{canManageGuild && channel?.guildId && <DisableInvitesButton guildId={channel.guildId} />}
|
||||
</div>
|
||||
|
||||
{fetchStatus === 'pending' && (
|
||||
<div className={styles.spinnerContainer}>
|
||||
|
||||
@@ -135,7 +135,7 @@ const ChannelWebhooksTab: React.FC<{channelId: string}> = observer(({channelId})
|
||||
</div>
|
||||
)}
|
||||
|
||||
{canManageWebhooks && !(fetchStatus === 'success' && (!webhooks || webhooks.length === 0)) && (
|
||||
{canManageWebhooks && (
|
||||
<div className={styles.buttonContainer}>
|
||||
<Button onClick={handleCreateQuick} variant="primary" disabled={fetchStatus === 'pending'} small>
|
||||
<Trans>Create Webhook</Trans>
|
||||
|
||||
@@ -73,9 +73,7 @@ const GuildInvitesTab: React.FC<{guildId: string}> = observer(({guildId}) => {
|
||||
</p>
|
||||
</div>
|
||||
|
||||
{canManageGuild && !(fetchStatus === 'success' && invites && invites.length === 0) && (
|
||||
<DisableInvitesButton guildId={guildId} />
|
||||
)}
|
||||
{canManageGuild && <DisableInvitesButton guildId={guildId} />}
|
||||
|
||||
{fetchStatus === 'pending' && (
|
||||
<div className={styles.spinnerContainer}>
|
||||
|
||||
@@ -112,7 +112,7 @@ const GuildWebhooksTab: React.FC<{guildId: string}> = observer(({guildId}) => {
|
||||
</div>
|
||||
)}
|
||||
|
||||
{canManageWebhooks && !(fetchStatus === 'success' && sortedWebhooks.length === 0) && (
|
||||
{canManageWebhooks && (
|
||||
<div className={styles.infoBox}>
|
||||
<Trans>
|
||||
To create a webhook, open the channel's settings and use the <strong>Webhooks</strong> tab. You can still
|
||||
|
||||
Reference in New Issue
Block a user