Show 8 friends on mobile instead of 4

This commit is contained in:
Kalle
2026-03-24 20:52:49 +02:00
parent 48152e1185
commit d1dcc5c071
2 changed files with 6 additions and 2 deletions

View File

@@ -52,6 +52,8 @@ import notificationPopoverStyles from "./NotificationPopover.module.css";
import { TopNavMenus } from "./TopNavMenus";
import { TopRightButtons } from "./TopRightButtons";
const MAX_DESKTOP_FRIENDS = 4;
function useTimeFormat() {
const { i18n } = useTranslation();
@@ -310,7 +312,9 @@ export function Layout({
{t("front:sideNav.friends")}
</SideNavHeader>
{friends.length > 0 ? (
friends.map((friend) => <FriendMenu key={friend.id} {...friend} />)
friends
.slice(0, MAX_DESKTOP_FRIENDS)
.map((friend) => <FriendMenu key={friend.id} {...friend} />)
) : (
<div className={styles.sideNavEmpty}>
{user

View File

@@ -52,7 +52,7 @@ export type SidebarFriend = {
};
const MAX_EVENTS_VISIBLE = 5;
const MAX_FRIENDS_VISIBLE = 4;
const MAX_FRIENDS_VISIBLE = 8;
const MAX_STREAMS_VISIBLE = 5;
const UPCOMING_TOURNAMENT_WINDOW_DAYS = 3;
const SENDOUQ_QUOTA = 2;