From bdf8c56d77558e0156cbbd01595eb4ac25c629dc Mon Sep 17 00:00:00 2001
From: TheSawkit <23707419+TheSawkit@users.noreply.github.com>
Date: Tue, 9 Jun 2026 17:27:55 +0200
Subject: [PATCH 1/3] Fix : Update BASE_URL to point to the correct production
environment
---
components/shared/PWAInstallPrompt.tsx | 2 +-
lib/metadata.ts | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/components/shared/PWAInstallPrompt.tsx b/components/shared/PWAInstallPrompt.tsx
index bd3ba82..253f797 100644
--- a/components/shared/PWAInstallPrompt.tsx
+++ b/components/shared/PWAInstallPrompt.tsx
@@ -30,7 +30,7 @@ export function PWAInstallPrompt() {
'transition-transform duration-(--duration-slow) ease-apple',
visible
? 'translate-y-0'
- : '-translate-y-[200%] pointer-events-none'
+ : 'translate-y-[-200%] pointer-events-none'
)}
>
diff --git a/lib/metadata.ts b/lib/metadata.ts
index 2f9b438..6ff3067 100644
--- a/lib/metadata.ts
+++ b/lib/metadata.ts
@@ -4,7 +4,7 @@ import { SUPPORTED_LANGUAGES } from '@/lib/i18n/config';
import type { Language } from '@/lib/i18n/translations';
export const BASE_URL =
- process.env.NEXT_PUBLIC_BASE_URL || 'https://reelmark.app';
+ process.env.NEXT_PUBLIC_BASE_URL || 'https://reelmark-silexio.vercel.app';
interface MediaMetadataOptions {
title: string;
From b668ff44d3cd39125e3df904fd91d038ecfe5349 Mon Sep 17 00:00:00 2001
From: TheSawkit <23707419+TheSawkit@users.noreply.github.com>
Date: Tue, 9 Jun 2026 17:31:37 +0200
Subject: [PATCH 2/3] Fix : Update BASE_URL references to point to the new
production environment
---
app/auth/actions.ts | 2 +-
tests/unit/metadata.test.ts | 18 +++++++++---------
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/app/auth/actions.ts b/app/auth/actions.ts
index cd8f221..853909e 100644
--- a/app/auth/actions.ts
+++ b/app/auth/actions.ts
@@ -37,7 +37,7 @@ function mapAuthError(message: string, t: AuthTranslations): string {
async function getOrigin(): Promise {
const h = await headers();
const proto = h.get('x-forwarded-proto') ?? 'https';
- const host = h.get('x-forwarded-host') ?? h.get('host') ?? 'reelmark.app';
+ const host = h.get('x-forwarded-host') ?? h.get('host') ?? 'reelmark-silexio.vercel.app';
return `${proto}://${host}`;
}
diff --git a/tests/unit/metadata.test.ts b/tests/unit/metadata.test.ts
index 1875361..e20681d 100644
--- a/tests/unit/metadata.test.ts
+++ b/tests/unit/metadata.test.ts
@@ -53,9 +53,9 @@ describe('buildPageMetadata', () => {
it('sets alternates.canonical when provided', () => {
const meta = buildPageMetadata('Page', 'Desc', {
- canonical: 'https://reelmark.app/page',
+ canonical: 'https://reelmark-silexio.vercel.app/page',
});
- expect(meta.alternates?.canonical).toBe('https://reelmark.app/page');
+ expect(meta.alternates?.canonical).toBe('https://reelmark-silexio.vercel.app/page');
});
it('omits alternates when canonical is absent', () => {
@@ -81,11 +81,11 @@ describe('buildMediaMetadata', () => {
'A team of explorers travel through a wormhole.'
);
expect(meta.alternates?.canonical).toBe(
- 'https://reelmark.app/en/movie/157336'
+ 'https://reelmark-silexio.vercel.app/en/movie/157336'
);
expect(meta.alternates?.languages).toMatchObject({
- en: 'https://reelmark.app/en/movie/157336',
- fr: 'https://reelmark.app/fr/movie/157336',
+ en: 'https://reelmark-silexio.vercel.app/en/movie/157336',
+ fr: 'https://reelmark-silexio.vercel.app/fr/movie/157336',
});
});
@@ -134,16 +134,16 @@ describe('buildMediaMetadata', () => {
describe('localizedAlternates', () => {
it('builds canonical on the given language with hreflang alternates', () => {
const alt = localizedAlternates('fr', '/movie/157336');
- expect(alt.canonical).toBe('https://reelmark.app/fr/movie/157336');
+ expect(alt.canonical).toBe('https://reelmark-silexio.vercel.app/fr/movie/157336');
expect(alt.languages).toMatchObject({
- en: 'https://reelmark.app/en/movie/157336',
- fr: 'https://reelmark.app/fr/movie/157336',
+ en: 'https://reelmark-silexio.vercel.app/en/movie/157336',
+ fr: 'https://reelmark-silexio.vercel.app/fr/movie/157336',
});
});
it('maps the root path to the bare locale prefix', () => {
expect(localizedAlternates('en', '/').canonical).toBe(
- 'https://reelmark.app/en'
+ 'https://reelmark-silexio.vercel.app/en'
);
});
});
From 9963297ddf9ae46eb39fce51a5c6b03504921ae9 Mon Sep 17 00:00:00 2001
From: TheSawkit <23707419+TheSawkit@users.noreply.github.com>
Date: Tue, 9 Jun 2026 17:55:29 +0200
Subject: [PATCH 3/3] CI : Update base URL for metadata tests and auth actions
---
app/auth/actions.ts | 5 ++++-
lib/metadata.ts | 2 +-
tests/unit/metadata.test.ts | 22 +++++++++-------------
3 files changed, 14 insertions(+), 15 deletions(-)
diff --git a/app/auth/actions.ts b/app/auth/actions.ts
index 853909e..4840892 100644
--- a/app/auth/actions.ts
+++ b/app/auth/actions.ts
@@ -37,7 +37,10 @@ function mapAuthError(message: string, t: AuthTranslations): string {
async function getOrigin(): Promise {
const h = await headers();
const proto = h.get('x-forwarded-proto') ?? 'https';
- const host = h.get('x-forwarded-host') ?? h.get('host') ?? 'reelmark-silexio.vercel.app';
+ const host =
+ h.get('x-forwarded-host') ??
+ h.get('host') ??
+ 'reelmark-silexio.vercel.app';
return `${proto}://${host}`;
}
diff --git a/lib/metadata.ts b/lib/metadata.ts
index 6ff3067..d97e346 100644
--- a/lib/metadata.ts
+++ b/lib/metadata.ts
@@ -4,7 +4,7 @@ import { SUPPORTED_LANGUAGES } from '@/lib/i18n/config';
import type { Language } from '@/lib/i18n/translations';
export const BASE_URL =
- process.env.NEXT_PUBLIC_BASE_URL || 'https://reelmark-silexio.vercel.app';
+ process.env.NEXT_PUBLIC_BASE_URL || 'https://localhost:3000';
interface MediaMetadataOptions {
title: string;
diff --git a/tests/unit/metadata.test.ts b/tests/unit/metadata.test.ts
index e20681d..c9c6ef4 100644
--- a/tests/unit/metadata.test.ts
+++ b/tests/unit/metadata.test.ts
@@ -53,9 +53,9 @@ describe('buildPageMetadata', () => {
it('sets alternates.canonical when provided', () => {
const meta = buildPageMetadata('Page', 'Desc', {
- canonical: 'https://reelmark-silexio.vercel.app/page',
+ canonical: `${BASE_URL}/page`,
});
- expect(meta.alternates?.canonical).toBe('https://reelmark-silexio.vercel.app/page');
+ expect(meta.alternates?.canonical).toBe(`${BASE_URL}/page`);
});
it('omits alternates when canonical is absent', () => {
@@ -80,12 +80,10 @@ describe('buildMediaMetadata', () => {
expect(meta.description).toBe(
'A team of explorers travel through a wormhole.'
);
- expect(meta.alternates?.canonical).toBe(
- 'https://reelmark-silexio.vercel.app/en/movie/157336'
- );
+ expect(meta.alternates?.canonical).toBe(`${BASE_URL}/en/movie/157336`);
expect(meta.alternates?.languages).toMatchObject({
- en: 'https://reelmark-silexio.vercel.app/en/movie/157336',
- fr: 'https://reelmark-silexio.vercel.app/fr/movie/157336',
+ en: `${BASE_URL}/en/movie/157336`,
+ fr: `${BASE_URL}/fr/movie/157336`,
});
});
@@ -134,16 +132,14 @@ describe('buildMediaMetadata', () => {
describe('localizedAlternates', () => {
it('builds canonical on the given language with hreflang alternates', () => {
const alt = localizedAlternates('fr', '/movie/157336');
- expect(alt.canonical).toBe('https://reelmark-silexio.vercel.app/fr/movie/157336');
+ expect(alt.canonical).toBe(`${BASE_URL}/fr/movie/157336`);
expect(alt.languages).toMatchObject({
- en: 'https://reelmark-silexio.vercel.app/en/movie/157336',
- fr: 'https://reelmark-silexio.vercel.app/fr/movie/157336',
+ en: `${BASE_URL}/en/movie/157336`,
+ fr: `${BASE_URL}/fr/movie/157336`,
});
});
it('maps the root path to the bare locale prefix', () => {
- expect(localizedAlternates('en', '/').canonical).toBe(
- 'https://reelmark-silexio.vercel.app/en'
- );
+ expect(localizedAlternates('en', '/').canonical).toBe(`${BASE_URL}/en`);
});
});