diff --git a/src/components/clusters/index.tsx b/src/components/clusters/index.tsx
index fabf62dc..fea0cd9d 100644
--- a/src/components/clusters/index.tsx
+++ b/src/components/clusters/index.tsx
@@ -26,7 +26,7 @@ import { createTheme, ThemeProvider } from '@mui/material/styles';
import MoreTimeIcon from '@mui/icons-material/MoreTime';
import ArrowCircleRightIcon from '@mui/icons-material/ArrowCircleRight';
import { useNavigate } from 'react-router-dom';
-import { DEFAULT_PAGE_SIZE ,MAX_PAGE_SIZE} from '../../lib/constants';
+import { DEFAULT_PAGE_SIZE, MAX_PAGE_SIZE } from '../../lib/constants';
const theme = createTheme({
breakpoints: {
@@ -409,17 +409,21 @@ export default function Clusters() {
))}
-
- {
- setPage(newPage);
- }}
- color="primary"
- size="small"
- />
-
+ {totalPages > 1 ? (
+
+ {
+ setPage(newPage);
+ }}
+ color="primary"
+ size="small"
+ />
+
+ ) : (
+ <>>
+ )}
);
diff --git a/src/components/clusters/show.tsx b/src/components/clusters/show.tsx
index 0914aecf..af4ad366 100644
--- a/src/components/clusters/show.tsx
+++ b/src/components/clusters/show.tsx
@@ -864,17 +864,21 @@ export default function ShowCluster() {
-
- {
- setSchedulerPage(newPage);
- }}
- color="primary"
- size="small"
- />
-
+ {schedulerTotalPages > 1 ? (
+
+ {
+ setSchedulerPage(newPage);
+ }}
+ color="primary"
+ size="small"
+ />
+
+ ) : (
+ <>>
+ )}
Seed Peer Cluster
@@ -1138,17 +1142,21 @@ export default function ShowCluster() {
-
- {
- setSeedPeerPage(newPage);
- }}
- color="primary"
- size="small"
- />
-
+ {seedPeerTotalPages > 1 ? (
+
+ {
+ setSeedPeerPage(newPage);
+ }}
+ color="primary"
+ size="small"
+ />
+
+ ) : (
+ <>>
+ )}
);
diff --git a/src/components/developer/tokens/index.tsx b/src/components/developer/tokens/index.tsx
index 899aae17..934a608d 100644
--- a/src/components/developer/tokens/index.tsx
+++ b/src/components/developer/tokens/index.tsx
@@ -199,125 +199,207 @@ export default function PersonalAccessTokens() {
Tokens you have generated that can be used to access the Dragonfly API.
-
- {showCopyColumn ? (
- <>
-
-
- {newToken}
-
-
+
+ {newToken}
+
+
+ {showCopyIcon ? (
+ {
+ setShowCopyIcon(false);
}}
- onClick={copyToken}
+ open={showCopyIcon}
+ disableFocusListener
+ disableHoverListener
+ disableTouchListener
+ title="copied!"
>
- {showCopyIcon ? (
- {
- setShowCopyIcon(false);
- }}
- open={showCopyIcon}
- disableFocusListener
- disableHoverListener
- disableTouchListener
- title="copied!"
- >
-
-
- ) : (
-
- )}
-
-
-
- >
- ) : (
- <>>
- )}
- {Array.isArray(tokens) &&
- tokens.map((item) => {
- return (
-
-
-
-
- {isLoading ? (
-
- ) : (
-
+
+ ) : (
+
+ )}
+
+
+ ) : (
+ <>>
+ )}
+
+ {tokens.length === 0 ? (
+
+ You don't have any tokens.
+
+ ) : (
+ <>
+
+ {Array.isArray(tokens) &&
+ tokens.map((item, index) => {
+ return index !== tokens.length - 1 ? (
+
+
+
+
+ {isLoading ? (
+
+ ) : (
+
+ {item.name}
+
+ )}
+ {isLoading ? (
+ <>
+ —
+
+ >
+ ) : (
+ — {item?.user?.name}
+ )}
+
+ {isLoading ? (
+
+ ) : (
+ <>
+
+ Expires on
+
+
+ {formatDate(item?.expired_at) || ''}.
+
+ >
+ )}
+
+
+
+
- {isLoading ? (
-
- ) : (
- <>
-
- Expires on
-
-
- {formatDate(item?.expired_at) || ''}.
-
- >
- )}
+
-
-
+ ) : (
+
+
+
+
+ {isLoading ? (
+
+ ) : (
+
+ {item.name}
+
+ )}
+ {isLoading ? (
+ <>
+ —
+
+ >
+ ) : (
+ — {item?.user?.name}
+ )}
+
+ {isLoading ? (
+
+ ) : (
+ <>
+
+ Expires on
+
+
+ {formatDate(item?.expired_at) || ''}.
+
+ >
+ )}
+
+
+
+
+
-
-
-
- );
- })}
-
-
- {
- setTokensPage(newPage);
- }}
- color="primary"
- size="small"
- />
-
+ );
+ })}
+
+ >
+ )}
+
+ {tokensTotalPages > 1 ? (
+
+ {
+ setTokensPage(newPage);
+ }}
+ color="primary"
+ size="small"
+ />
+
+ ) : (
+ <>>
+ )}
+