File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -161,6 +161,9 @@ export default function RootLayout({ children }) {
161161 { label : 'Privacy' , href : '/privacy' } ,
162162 { label : 'Terms' , href : '/terms' } ,
163163 { label : 'GitHub' , href : 'https://github.com/profullstack/qryptchat-web' } ,
164+ ...( process . env . NEXT_PUBLIC_ONION_URL && ! new URL ( SITE_URL ) . hostname . endsWith ( '.onion' )
165+ ? [ { label : 'Also on Tor' , href : process . env . NEXT_PUBLIC_ONION_URL } ]
166+ : [ ] ) ,
164167 ] }
165168 />
166169 }
Original file line number Diff line number Diff line change 11'use client' ;
22
3- // One footer row: links, copyright and the Profullstack ring come from
4- // @profullstack /footer, server-rendered in app/layout.jsx and passed in as
5- // `bottom`. The Tor mirror link sits just above it when configured.
3+ // The shared Profullstack footer is passed in by app/layout.jsx.
64export default function Footer ( { bottom } ) {
7- const onionUrl = process . env . NEXT_PUBLIC_ONION_URL ;
8- const isOnionSite = typeof window !== 'undefined' && window . location . hostname . endsWith ( '.onion' ) ;
9-
10- return (
11- < footer className = "footer" >
12- { ! isOnionSite && onionUrl && (
13- < p className = "footer-onion" >
14- 🧅 Also on Tor: < a href = { onionUrl } target = "_blank" rel = "noopener noreferrer" > { onionUrl } </ a >
15- </ p >
16- ) }
17- { bottom }
18-
19- < style > { `
20- .footer { background: var(--color-bg-secondary); border-top: 1px solid var(--color-border-primary); color: var(--color-text-secondary); }
21- .footer-onion { margin: 0; padding-top: var(--space-4); text-align: center; font-size: 0.75rem; word-break: break-all; }
22- .footer-onion a { color: var(--color-brand-primary); }
23- ` } </ style >
24- </ footer >
25- ) ;
5+ return bottom ;
266}
You can’t perform that action at this time.
0 commit comments