fix: popout chat

This commit is contained in:
Alejandro Gomez
2023-06-26 15:46:48 +02:00
parent bda0d36f9a
commit 9f5b17ac3c
4 changed files with 44 additions and 11 deletions

View File

@ -1,5 +1,13 @@
.popout-chat {
grid-area: main-content;
}
.popout-chat .live-chat {
height: calc(100vh - 20px);
margin-left: 0;
}
.popout-chat .live-chat {
height: calc(100vh);
padding: 10px;
border: unset;
border-radius: unset;

View File

@ -7,10 +7,15 @@ export function ChatPopout() {
const params = useParams();
const link = parseNostrLink(params.id!);
return <div className="popout-chat">
<LiveChat link={link} options={{
return (
<div className="popout-chat">
<LiveChat
link={link}
options={{
canWrite: false,
showHeader: false
}} />
showHeader: false,
}}
/>
</div>
);
}

View File

@ -20,10 +20,24 @@
grid-template-columns: 1fr;
}
.popout-chat {
display: grid;
grid-template-areas:
"main-content";
grid-template-rows: 1fr;
grid-template-columns: 1fr;
height: 100vh;
gap: 0;
}
.live-chat {
max-height: calc(100vh - 385px);
}
.popout-chat .live-chat {
max-height: unset;
}
@media (min-width: 768px) {
.video-content video {
height: calc(100vh - 64px);

View File

@ -80,7 +80,13 @@ export function LayoutPage() {
return (
<div
className={location.pathname.startsWith("/live/") ? "page" : "page home"}
className={
location.pathname === "/"
? "page home"
: location.pathname.startsWith("/chat/")
? "page chat"
: "page"
}
>
<header>
<div className="logo" onClick={() => navigate("/")}>