Hide discord & back button with launcher
This commit is contained in:
1 file changed
+6
-2
@@ -7,6 +7,7 @@ import { BirdColor } from '../chatroom/page'
|
||||
import axios from 'axios'
|
||||
import { GetIconForUser } from '@/util/bd'
|
||||
import Image from 'next/image'
|
||||
import { useSearchParams } from 'next/navigation'
|
||||
|
||||
interface BaseEntry {
|
||||
id: number
|
||||
@@ -86,6 +87,7 @@ export default function BerryDashLeaderboards () {
|
||||
const [entries, setEntries] = useState<(LeaderboardEntry | Account)[]>([])
|
||||
const backButtonRef = useRef<HTMLAnchorElement>(null)
|
||||
const backButtonRef2 = useRef<HTMLButtonElement>(null)
|
||||
const params = useSearchParams()
|
||||
|
||||
const Refresh = useCallback(async () => {
|
||||
setGettingEntries(true)
|
||||
@@ -158,7 +160,9 @@ export default function BerryDashLeaderboards () {
|
||||
return (
|
||||
<div className='box'>
|
||||
{selected == -1 ? (
|
||||
<BackButton href='/game/berry-dash' refLink={backButtonRef} />
|
||||
!params.get('launcher') && (
|
||||
<BackButton href='/game/berry-dash' refLink={backButtonRef} />
|
||||
)
|
||||
) : (
|
||||
<BackButton
|
||||
onClick={() => {
|
||||
@@ -170,7 +174,7 @@ export default function BerryDashLeaderboards () {
|
||||
refButton={backButtonRef2}
|
||||
/>
|
||||
)}
|
||||
<DiscordButton />
|
||||
{!params.get('launcher') && <DiscordButton />}
|
||||
<p className='px-20 mb-2 -mt-2 text-center text-2xl'>
|
||||
Berry Dash Leaderboards
|
||||
</p>
|
||||
|
||||
Reference in new issue
Block a user