Skip to content

Commit 5c9f425

Browse files
committed
feat(leaderboard): show current page in go-to-page button
1 parent aa7d260 commit 5c9f425

2 files changed

Lines changed: 4 additions & 12 deletions

File tree

frontend/src/ts/components/pages/leaderboard/Navigation.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { showSimpleModal } from "../../../states/simple-modal";
55
import { cn } from "../../../utils/cn";
66
import { Button } from "../../common/Button";
77
import { LoadingCircle } from "../../common/LoadingCircle";
8-
import { PageIndicator } from "./PageIndicator";
98

109
export function Navigation(props: {
1110
lastPage: number;
@@ -28,7 +27,6 @@ export function Navigation(props: {
2827
<Show when={props.isLoading}>
2928
<LoadingCircle color="sub" class="text-2xl" />
3029
</Show>
31-
<PageIndicator currentPage={props.currentPage} />
3230
<Button
3331
onClick={() => props.onPageChange(0)}
3432
fa={{ icon: "fa-crown", fixedWidth: true }}
@@ -85,7 +83,10 @@ export function Navigation(props: {
8583
fa={{ icon: "fa-hashtag", fixedWidth: true }}
8684
class={buttonClass}
8785
disabled={props.lastPage <= 1}
88-
/>
86+
>
87+
{" "}
88+
{props.currentPage + 1}
89+
</Button>
8990
<Button
9091
onClick={() => props.onPageChange((old) => old + 1)}
9192
fa={{ icon: "fa-chevron-right", fixedWidth: true }}

frontend/src/ts/components/pages/leaderboard/PageIndicator.tsx

Lines changed: 0 additions & 9 deletions
This file was deleted.

0 commit comments

Comments
 (0)