fix: removed client-side Link from server components

This commit is contained in:
Riccardo
2024-02-23 16:17:18 +01:00
parent 01134bb4e7
commit c20d0061a7
8 changed files with 110 additions and 11 deletions

View File

@@ -1,3 +1,4 @@
'use client';
import Link from 'next/link';
import { Button } from '../ui/button';

View File

@@ -1,3 +1,4 @@
'use client';
import Link from 'next/link';
import { usePathname } from 'next/navigation';
import { CustomLink } from './customLink';

View File

@@ -1,4 +1,3 @@
import { CustomLink } from '../custom/customLink';
import { Note } from './components/note';
import Template from './template';
@@ -22,10 +21,9 @@ export default function ConfirmationTemplate(code: string) {
justifyContent: 'center'
}}
>
<CustomLink
path={`${process.env.HOME_URL}/confirmation?code=${code}`}
text='Confirm subscription'
/>
<a href={`${process.env.HOME_URL}/confirmation?code=${code}`}>
{'Confirm subscription'}
</a>
</div>
<Note>
If you didn&apos;t subscribe to our newsletter, please ignore this

View File

@@ -1,4 +1,3 @@
import { CustomLink } from '../custom/customLink';
import { Note } from './components/note';
import Template from './template';
@@ -22,7 +21,7 @@ export default function UnsubscribeTemplate() {
justifyContent: 'center'
}}
>
<CustomLink path='/' text='Re-subscribe' />
<a href={`${process.env.HOME_URL}/`}>{'Re-subscribe'}</a>
</div>
<Note>
If you have any questions or concerns, please feel free to{' '}