mirror of
https://github.com/owncast/owncast.git
synced 2024-12-20 16:24:16 +03:00
26 lines
745 B
TypeScript
26 lines
745 B
TypeScript
import { Layout } from 'antd';
|
|
import { useRecoilValue } from 'recoil';
|
|
import { ChatState } from '../../../interfaces/application-state';
|
|
import { OwncastLogo, UserDropdown } from '../../common';
|
|
import { chatStateAtom } from '../../stores/ClientConfigStore';
|
|
import s from './Header.module.scss';
|
|
|
|
const { Header } = Layout;
|
|
|
|
interface Props {
|
|
name: string;
|
|
}
|
|
|
|
export default function HeaderComponent({ name = 'Your stream title' }: Props) {
|
|
const chatState = useRecoilValue<ChatState>(chatStateAtom);
|
|
|
|
return (
|
|
<Header className={`${s.header}`}>
|
|
<div className={`${s.logo}`}>
|
|
<OwncastLogo variant="contrast" />
|
|
<span>{name}</span>
|
|
</div>
|
|
<UserDropdown chatState={chatState} />
|
|
</Header>
|
|
);
|
|
}
|