mirror of
https://github.com/BradNut/umami
synced 2025-09-08 17:40:29 +00:00
Merge pull request #438 from gabehab/master
Add link to header title when appropriate
This commit is contained in:
commit
13dddb3764
1 changed files with 13 additions and 4 deletions
|
|
@ -10,12 +10,21 @@ import Arrow from 'assets/arrow-right.svg';
|
|||
import styles from './WebsiteHeader.module.css';
|
||||
|
||||
export default function WebsiteHeader({ websiteId, title, domain, showLink = false }) {
|
||||
let TitleHeader = showLink ? (
|
||||
<Link href="/website/[...id]" as={`/website/${websiteId}/${title}`}>
|
||||
<Favicon domain={domain} />
|
||||
{title}
|
||||
</Link>
|
||||
) : (
|
||||
<div>
|
||||
<Favicon domain={domain} />
|
||||
{title}
|
||||
</div>
|
||||
);
|
||||
|
||||
return (
|
||||
<PageHeader>
|
||||
<div className={styles.title}>
|
||||
<Favicon domain={domain} />
|
||||
{title}
|
||||
</div>
|
||||
<div className={styles.title}>{TitleHeader}</div>
|
||||
<ActiveUsers className={styles.active} websiteId={websiteId} />
|
||||
<ButtonLayout align="right">
|
||||
<RefreshButton websiteId={websiteId} />
|
||||
|
|
|
|||
Loading…
Reference in a new issue