Skip to content

Commit 064ab5f

Browse files
committed
Refactor AdminRoom component to simplify queue display
- Removed unnecessary conditional rendering for sound and flash notifications in the Speaking Queue section of the AdminRoom component, streamlining the layout and improving readability. Signed-off-by: Pete Cheslock <[email protected]>
1 parent a786d15 commit 064ab5f

File tree

1 file changed

+5
-27
lines changed

1 file changed

+5
-27
lines changed

src/components/AdminRoom.jsx

Lines changed: 5 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -337,33 +337,11 @@ const AdminRoom = ({ userSession, onSessionEnd }) => {
337337
{/* Queue */}
338338
<div className="bg-white rounded-lg shadow-sm">
339339
<div className="p-6 border-b">
340-
<div className="flex items-center justify-between">
341-
<div>
342-
<h2 className="text-xl font-semibold text-gray-900">Speaking Queue</h2>
343-
<p className="text-gray-600 mt-1">
344-
{queue.length === 0 ? 'No one in queue' : `${queue.length} person${queue.length > 1 ? 's' : ''} waiting to speak`}
345-
</p>
346-
</div>
347-
{(soundEnabled || flashEnabled) && (
348-
<div className="flex items-center gap-2">
349-
{soundEnabled && (
350-
<div className="flex items-center text-sm text-green-600 bg-green-50 px-3 py-1 rounded-full">
351-
<svg className="w-4 h-4 mr-1" fill="none" stroke="currentColor" viewBox="0 0 24 24">
352-
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M15.536 8.464a5 5 0 010 7.072m2.828-9.9a9 9 0 010 12.728M5.586 15H4a1 1 0 01-1-1v-4a1 1 0 011-1h1.586l4.707-4.707C10.923 3.663 12 4.109 12 5v14c0 .891-1.077 1.337-1.707.707L5.586 15z" />
353-
</svg>
354-
Sound
355-
</div>
356-
)}
357-
{flashEnabled && (
358-
<div className="flex items-center text-sm text-yellow-600 bg-yellow-50 px-3 py-1 rounded-full">
359-
<svg className="w-4 h-4 mr-1" fill="none" stroke="currentColor" viewBox="0 0 24 24">
360-
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M13 10V3L4 14h7v7l9-11h-7z" />
361-
</svg>
362-
Flash
363-
</div>
364-
)}
365-
</div>
366-
)}
340+
<div>
341+
<h2 className="text-xl font-semibold text-gray-900">Speaking Queue</h2>
342+
<p className="text-gray-600 mt-1">
343+
{queue.length === 0 ? 'No one in queue' : `${queue.length} person${queue.length > 1 ? 's' : ''} waiting to speak`}
344+
</p>
367345
</div>
368346
</div>
369347

0 commit comments

Comments
 (0)