Skip to content

Commit

Permalink
Merge pull request #327 from AlgoNode/nodely/footer-item-env
Browse files Browse the repository at this point in the history
feat(ui): optional extra footer item
  • Loading branch information
pbennett authored Nov 22, 2024
2 parents 4d353bd + 8932788 commit f2c12fe
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 9 deletions.
27 changes: 18 additions & 9 deletions ui/src/components/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,22 @@ const navigation = [
},
]

export function FooterExtraItem() {
return (
<>
<span className="mx-1 opacity-50">|</span>{' '}
<a
href={import.meta.env.VITE_FOOTER_EXTRA_ITEM_HREF}
className="link hover:text-foreground"
target="_blank"
rel="noopener noreferrer"
>
{import.meta.env.VITE_FOOTER_EXTRA_ITEM}
</a>
</>
)
}

export function Footer() {
return (
<footer className="bg-background" aria-labelledby="footer-heading">
Expand All @@ -53,15 +69,8 @@ export function Footer() {
</div>
<div className="mt-8 md:order-1 md:mt-0">
<p className="text-center text-sm leading-5 text-stone-600 dark:text-stone-400">
Réti Pooling v{__APP_VERSION__} <span className="mx-1 opacity-50">|</span>{' '}
<a
href="https://github.com/algorandfoundation/reti"
className="link hover:text-foreground"
target="_blank"
rel="noopener noreferrer"
>
TxnLab/reti
</a>
Réti Pooling v{__APP_VERSION__}
{import.meta.env.VITE_FOOTER_EXTRA_ITEM && FooterExtraItem()}
</p>
</div>
</div>
Expand Down
3 changes: 3 additions & 0 deletions ui/src/vite-env.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ interface ImportMetaEnv {
readonly VITE_KMD_PORT: string
readonly VITE_KMD_PASSWORD: string
readonly VITE_KMD_WALLET: string

readonly VITE_FOOTER_EXTRA_ITEM: string
readonly VITE_FOOTER_EXTRA_ITEM_HREF: string
}

interface ImportMeta {
Expand Down

1 comment on commit f2c12fe

@vercel
Copy link

@vercel vercel bot commented on f2c12fe Nov 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

reti – ./

reti-nodely.vercel.app
reti-git-dev-nodely.vercel.app
fnet.reti.nodly.io

Please sign in to comment.