Support hiding activity from admin accounts not associated with the server
This commit is contained in:
parent
95de4c30fc
commit
cf01490883
4 changed files with 40 additions and 11 deletions
|
@ -26,6 +26,10 @@ const PaginationFooter = ({ pagination, className, onPageSelect }: Props) => {
|
|||
}
|
||||
}
|
||||
|
||||
if (pagination.total === 0) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return (
|
||||
<div className={classNames('flex items-center justify-between my-2', className)}>
|
||||
<p className={'text-sm text-neutral-500'}>
|
||||
|
|
|
@ -48,13 +48,16 @@ export default () => {
|
|||
{!data && isValidating ?
|
||||
<Spinner centered/>
|
||||
:
|
||||
<div className={'bg-gray-700'}>
|
||||
{data?.items.map((activity) => (
|
||||
<ActivityLogEntry key={activity.timestamp.toString() + activity.event} activity={activity}>
|
||||
<span/>
|
||||
</ActivityLogEntry>
|
||||
))}
|
||||
</div>
|
||||
!data?.items.length ?
|
||||
<p className={'text-sm text-center text-gray-400'}>No activity logs available for this server.</p>
|
||||
:
|
||||
<div className={'bg-gray-700'}>
|
||||
{data?.items.map((activity) => (
|
||||
<ActivityLogEntry key={activity.timestamp.toString() + activity.event} activity={activity}>
|
||||
<span/>
|
||||
</ActivityLogEntry>
|
||||
))}
|
||||
</div>
|
||||
}
|
||||
{data && <PaginationFooter
|
||||
pagination={data.pagination}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue