mirror of
https://github.com/umami-software/umami.git
synced 2026-02-12 08:37:13 +01:00
Redirect to single allowed section on share page.
This commit is contained in:
parent
af7f7adf5b
commit
c9f6653b62
3 changed files with 52 additions and 8 deletions
23
src/app/share/[...shareId]/ShareFooter.tsx
Normal file
23
src/app/share/[...shareId]/ShareFooter.tsx
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
import { Row, Text } from '@umami/react-zen';
|
||||
import type { WhiteLabel } from '@/app/api/share/[shareId]/route';
|
||||
import { CURRENT_VERSION, HOMEPAGE_URL } from '@/lib/constants';
|
||||
|
||||
export function Footer({ whiteLabel }: { whiteLabel?: WhiteLabel }) {
|
||||
if (whiteLabel) {
|
||||
return (
|
||||
<Row as="footer" paddingY="6" justifyContent="flex-end">
|
||||
<a href={whiteLabel.url} target="_blank">
|
||||
<Text weight="bold">{whiteLabel.name}</Text>
|
||||
</a>
|
||||
</Row>
|
||||
);
|
||||
}
|
||||
|
||||
return (
|
||||
<Row as="footer" paddingY="6" justifyContent="flex-end">
|
||||
<a href={HOMEPAGE_URL} target="_blank">
|
||||
<Text weight="bold">umami</Text> {`v${CURRENT_VERSION}`}
|
||||
</a>
|
||||
</Row>
|
||||
);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue