From 30a3bba112c04c5710987d9da8f15514df925bb0 Mon Sep 17 00:00:00 2001 From: Aurastic <33085835+ISenseAura@users.noreply.github.com> Date: Tue, 22 Jul 2025 16:28:05 +0530 Subject: [PATCH] Preact: Show spotlight rooms on rooms list (#2476) --- play.pokemonshowdown.com/src/panel-rooms.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/play.pokemonshowdown.com/src/panel-rooms.tsx b/play.pokemonshowdown.com/src/panel-rooms.tsx index 56b17d725..d58a8541e 100644 --- a/play.pokemonshowdown.com/src/panel-rooms.tsx +++ b/play.pokemonshowdown.com/src/panel-rooms.tsx @@ -106,11 +106,15 @@ class RoomsPanel extends PSRoomPanel { if (!searchid) { const roomsCache = PS.mainmenu.roomsCache; - const officialRooms = [], chatRooms = [], hiddenRooms = []; + let spotLightLabel = ''; + const officialRooms = [], chatRooms = [], hiddenRooms = [], spotLightRooms = []; for (const room of roomsCache.chat || []) { if (room.section !== this.section && this.section !== '') continue; if (room.privacy === 'hidden') { hiddenRooms.push(room); + } else if (room.spotlight) { + spotLightLabel = room.spotlight; + spotLightRooms.push(room); } else if (room.section === 'Official') { officialRooms.push(room); } else { @@ -119,6 +123,7 @@ class RoomsPanel extends PSRoomPanel { } return [ ["Official chat rooms", officialRooms], + [spotLightLabel, spotLightRooms], ["Chat rooms", chatRooms], ["Hidden rooms", hiddenRooms], ];