mirror of
https://github.com/cinnyapp/cinny.git
synced 2025-11-10 01:00:28 +03:00
Re-arrange more options and add checks for each option to see if it is a call room (probably should manage a state to see if a header is already on screen and provide a slightly modified visual based on that for call rooms)
This commit is contained in:
parent
7228c2e35f
commit
02ac70affc
1 changed files with 88 additions and 84 deletions
|
|
@ -344,25 +344,7 @@ export function RoomViewHeader() {
|
|||
)}
|
||||
</Box>
|
||||
</Box>
|
||||
{(room.isCallRoom() && !isDirectMessage() && (
|
||||
<Box>
|
||||
<TooltipProvider
|
||||
position="Bottom"
|
||||
offset={4}
|
||||
tooltip={
|
||||
<Tooltip>
|
||||
<Text>Chat</Text>
|
||||
</Tooltip>
|
||||
}
|
||||
>
|
||||
{(triggerRef) => (
|
||||
<IconButton ref={triggerRef} onClick={toggleChat}>
|
||||
<Icon size="400" src={Icons.Message} />
|
||||
</IconButton>
|
||||
)}
|
||||
</TooltipProvider>
|
||||
</Box>
|
||||
)) || (
|
||||
|
||||
<Box shrink="No">
|
||||
{false && isDirectMessage() && (
|
||||
<TooltipProvider
|
||||
|
|
@ -382,7 +364,8 @@ export function RoomViewHeader() {
|
|||
)}
|
||||
</TooltipProvider>
|
||||
)}
|
||||
{!ecryptedRoom && (
|
||||
|
||||
{!ecryptedRoom && !room.isCallRoom() && (
|
||||
<TooltipProvider
|
||||
position="Bottom"
|
||||
offset={4}
|
||||
|
|
@ -399,6 +382,7 @@ export function RoomViewHeader() {
|
|||
)}
|
||||
</TooltipProvider>
|
||||
)}
|
||||
{!room.isCallRoom() && (
|
||||
<TooltipProvider
|
||||
position="Bottom"
|
||||
offset={4}
|
||||
|
|
@ -436,6 +420,8 @@ export function RoomViewHeader() {
|
|||
</IconButton>
|
||||
)}
|
||||
</TooltipProvider>
|
||||
)}
|
||||
{!room.isCallRoom() && (
|
||||
<PopOut
|
||||
anchor={pinMenuAnchor}
|
||||
position="Bottom"
|
||||
|
|
@ -455,8 +441,9 @@ export function RoomViewHeader() {
|
|||
</FocusTrap>
|
||||
}
|
||||
/>
|
||||
)}
|
||||
|
||||
{screenSize === ScreenSize.Desktop && (
|
||||
{!room.isCallRoom() && screenSize === ScreenSize.Desktop && (
|
||||
<TooltipProvider
|
||||
position="Bottom"
|
||||
offset={4}
|
||||
|
|
@ -473,6 +460,7 @@ export function RoomViewHeader() {
|
|||
)}
|
||||
</TooltipProvider>
|
||||
)}
|
||||
|
||||
<TooltipProvider
|
||||
position="Bottom"
|
||||
align="End"
|
||||
|
|
@ -509,8 +497,24 @@ export function RoomViewHeader() {
|
|||
</FocusTrap>
|
||||
}
|
||||
/>
|
||||
</Box>
|
||||
{room.isCallRoom() && !isDirectMessage() && (
|
||||
<TooltipProvider
|
||||
position="Bottom"
|
||||
offset={4}
|
||||
tooltip={
|
||||
<Tooltip>
|
||||
<Text>Chat</Text>
|
||||
</Tooltip>
|
||||
}
|
||||
>
|
||||
{(triggerRef) => (
|
||||
<IconButton ref={triggerRef} onClick={toggleChat}>
|
||||
<Icon size="400" src={Icons.Message} />
|
||||
</IconButton>
|
||||
)}
|
||||
</TooltipProvider>
|
||||
)}
|
||||
</Box>
|
||||
</Box>
|
||||
</PageHeader>
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue