diff --git a/client/src/UserList.tsx b/client/src/UserList.tsx index 46a2d98..62e1cce 100644 --- a/client/src/UserList.tsx +++ b/client/src/UserList.tsx @@ -146,121 +146,121 @@ const UserList: React.FC = (props: UserListProps) => { }, [users, sendJsonMessage]); return ( - - - - {users?.map((user) => ( - - - - -
{user.name ? user.name : user.session_id}
- {user.protected && ( -
- 🔒 -
- )} + + + + + {users?.map((user) => ( + + + + +
{user.name ? user.name : user.session_id}
+ {user.protected && ( +
+ 🔒 +
+ )} + {user.bot_instance_id && ( +
+ 🤖 +
+ )} +
{user.bot_instance_id && ( -
- 🤖 -
+ + {user.bot_run_id && ( + handleOpenBotConfig(user)} + style={{ width: "24px", height: "24px", fontSize: "0.7em" }} + title="Configure bot" + > + + + )} + + )}
- {user.bot_instance_id && ( - - {user.bot_run_id && ( - handleOpenBotConfig(user)} - style={{ width: "24px", height: "24px", fontSize: "0.7em" }} - title="Configure bot" - > - - - )} - - - )} + {user.name && !user.live &&
}
- {user.name && !user.live &&
} + {user.name && user.live && peers[user.session_id] && (user.local || user.has_media !== false) ? ( + + ) : user.name && user.live && user.has_media === false ? ( +
+ 💬 Chat Only +
+ ) : ( + + )}
- {user.name && user.live && peers[user.session_id] && (user.local || user.has_media !== false) ? ( - - ) : user.name && user.live && user.has_media === false ? ( -
- 💬 Chat Only -
- ) : ( - - )} -
- ))} -
+ ))} + - {/* Bot Configuration Dialog */} - - Configure Bot - - {selectedBotForConfig && ( - { - console.log("Bot configuration updated:", config); - // Configuration updates are handled via WebSocket, so we don't need to do anything special here - }} - /> - )} - - - - - -
+ {/* Bot Configuration Dialog */} + + Configure Bot + + {selectedBotForConfig && ( + { + console.log("Bot configuration updated:", config); + // Configuration updates are handled via WebSocket, so we don't need to do anything special here + }} + /> + )} + + + + + + + ); };