Skip to content

Free & Open-Source Invoice Generator - No Sign-Up, No Ads, Instant PDF Export, 100% In-Browser, and Fully Customizable Templates.

feat: fix accordion component + some minor improvements (#238)

Vlad Sazonauddeac906951c
diff --git a/.husky/pre-commit b/.husky/pre-commit
index f857ea4..d3a5b92 100644
--- a/.husky/pre-commit
+++ b/.husky/pre-commit
@@ -1 +1 @@
-pnpm run lint-stage --verbose
+pnpm run lint-stage
diff --git a/.npmrc b/.npmrc
index d553782..7a610f9 100644
--- a/.npmrc
+++ b/.npmrc
@@ -5,6 +5,6 @@ save-exact=true
# https://pnpm.io/supply-chain-security
# https://pnpm.io/settings#minimumreleaseage
-minimum-release-age=7200 # 5 days,
+minimum-release-age=7200 # 5 days
block-exotic-subdeps=true
trust-policy=no-downgrade
\ No newline at end of file
diff --git a/e2e/changelog.test.ts b/e2e/changelog.test.ts
index 6684643..d45aa32 100644
--- a/e2e/changelog.test.ts
+++ b/e2e/changelog.test.ts
@@ -7,6 +7,18 @@ test.describe("Changelog page", () => {
// Verify the page is loaded
await expect(page).toHaveURL("/changelog");
+ // Check header visibility
+ const header = page.locator("header");
+ await expect(header).toBeVisible();
+
+ const goToAppButton = header.getByRole("link", {
+ name: "Open app",
+ exact: true,
+ });
+
+ await expect(goToAppButton).toBeVisible();
+ await expect(goToAppButton).toHaveAttribute("href", "/?template=default");
+
// Check main heading
await expect(
page.getByRole("heading", {
@@ -28,12 +40,32 @@ test.describe("Changelog page", () => {
// At least one entry should be visible
await expect(entryCards.first()).toBeVisible();
+
+ // Check footer visibility
+ const footer = page.locator("footer");
+ await expect(footer).toBeVisible();
+
+ const appLink = footer.getByRole("link", {
+ name: "Invoice Generator",
+ exact: true,
+ });
+
+ await expect(appLink).toBeVisible();
+ await expect(appLink).toHaveAttribute("href", "/");
+ await expect(appLink).not.toHaveAttribute("target", "_blank");
+
+ await expect(
+ footer.locator('[data-testid="footer-logos-social-links"]'),
+ ).toBeVisible();
});
test("should navigate to individual changelog entry", async ({ page }) => {
await page.goto("/changelog");
await expect(page).toHaveURL("/changelog");
+ // Check header visibility
+ await expect(page.locator("header")).toBeVisible();
+
// Find and click on the first changelog entry title link
// Find first changelog entry link and get its href
const firstEntryLink = page
@@ -48,10 +80,24 @@ test.describe("Changelog page", () => {
// Verify we navigated to the individual entry page
await expect(page).toHaveURL(href!);
+ // Check header visibility
+ const header = page.locator("header");
+ await expect(header).toBeVisible();
+
+ const goToAppButton = header.getByRole("link", {
+ name: "Open app",
+ exact: true,
+ });
+ await expect(goToAppButton).toBeVisible();
+ await expect(goToAppButton).toHaveAttribute("href", "/?template=default");
+
// Check that we're on an individual entry page by looking for "Back to All Posts" link
await expect(
page.getByRole("link", { name: "Back to All Posts" }),
).toBeVisible();
+
+ // Check footer visibility
+ await expect(page.locator("footer")).toBeVisible();
});
test("should display individual changelog entry content", async ({
@@ -61,6 +107,9 @@ test.describe("Changelog page", () => {
await page.goto("/changelog");
await expect(page).toHaveURL("/changelog");
+ // Check header visibility
+ await expect(page.locator("header")).toBeVisible();
+
// Find and click on the first changelog entry title link
// Find first changelog entry link and get its href
const firstEntryLink = page
@@ -111,6 +160,9 @@ test.describe("Changelog page", () => {
"href",
"https://easyinvoicepdf.com?ref=changelog",
);
+
+ // Check footer visibility
+ await expect(page.locator("footer")).toBeVisible();
});
test("should navigate back to changelog from individual entry", async ({
@@ -120,6 +172,9 @@ test.describe("Changelog page", () => {
await page.goto("/changelog");
await expect(page).toHaveURL("/changelog");
+ // Check header visibility
+ await expect(page.locator("header")).toBeVisible();
+
const firstEntryLink = page
.getByRole("link")
.filter({ has: page.getByRole("heading", { level: 2 }) })
@@ -141,6 +196,9 @@ test.describe("Changelog page", () => {
await expect(
page.getByRole("heading", { level: 1, name: "Changelog" }),
).toBeVisible();
+
+ // Check footer visibility
+ await expect(page.locator("footer")).toBeVisible();
});
test("should handle direct navigation to changelog entry", async ({
@@ -151,6 +209,9 @@ test.describe("Changelog page", () => {
await page.goto("/changelog");
await expect(page).toHaveURL("/changelog");
+ // Check header visibility
+ await expect(page.locator("header")).toBeVisible();
+
const firstEntryLink = page.locator('a[href^="/changelog/"]').first();
const href = await firstEntryLink.getAttribute("href");
@@ -166,5 +227,8 @@ test.describe("Changelog page", () => {
// Verify we can still navigate back
await page.getByRole("link", { name: "Back to All Posts" }).click();
await expect(page).toHaveURL("/changelog");
+
+ // Check footer visibility
+ await expect(page.locator("footer")).toBeVisible();
});
});
diff --git a/e2e/seo-landings.test.ts b/e2e/seo-landings.test.ts
index 7156a44..6c6db1b 100644
--- a/e2e/seo-landings.test.ts
+++ b/e2e/seo-landings.test.ts
@@ -31,6 +31,18 @@ test.describe("SEO landing pages", () => {
await expect(page).toHaveURL(path);
+ // Check header visibility
+ const header = page.locator("header");
+ await expect(header).toBeVisible();
+
+ const goToAppButton = header.getByRole("link", {
+ name: "Open app",
+ exact: true,
+ });
+
+ await expect(goToAppButton).toBeVisible();
+ await expect(goToAppButton).toHaveAttribute("href", "/?template=default");
+
await expect(
page.getByRole("heading", { level: 1, name: h1 }),
).toBeVisible();
@@ -67,6 +79,23 @@ test.describe("SEO landing pages", () => {
"href",
ctaHref,
);
+
+ // Check footer visibility
+ const footer = page.locator("footer");
+ await expect(footer).toBeVisible();
+
+ const appLink = footer.getByRole("link", {
+ name: "Invoice Generator",
+ exact: true,
+ });
+
+ await expect(appLink).toBeVisible();
+ await expect(appLink).toHaveAttribute("href", "/");
+ await expect(appLink).not.toHaveAttribute("target", "_blank");
+
+ await expect(
+ footer.locator('[data-testid="footer-logos-social-links"]'),
+ ).toBeVisible();
});
}
diff --git a/e2e/tos.test.ts b/e2e/tos.test.ts
index 9579d85..73ea0eb 100644
--- a/e2e/tos.test.ts
+++ b/e2e/tos.test.ts
@@ -6,6 +6,18 @@ test.describe("Terms of Service page", () => {
await expect(page).toHaveURL("/tos");
+ // Check header visibility
+ const header = page.locator("header");
+ await expect(header).toBeVisible();
+
+ const goToAppButton = header.getByRole("link", {
+ name: "Open app",
+ exact: true,
+ });
+
+ await expect(goToAppButton).toBeVisible();
+ await expect(goToAppButton).toHaveAttribute("href", "/?template=default");
+
await expect(page).toHaveTitle("Terms of Service | EasyInvoicePDF");
await expect(
@@ -59,5 +71,22 @@ test.describe("Terms of Service page", () => {
"href",
);
+
+ // Check footer visibility
+ const footer = page.locator("footer");
+ await expect(footer).toBeVisible();
+
+ const appLink = footer.getByRole("link", {
+ name: "Invoice Generator",
+ exact: true,
+ });
+
+ await expect(appLink).toBeVisible();
+ await expect(appLink).toHaveAttribute("href", "/");
+ await expect(appLink).not.toHaveAttribute("target", "_blank");
+
+ await expect(
+ footer.locator('[data-testid="footer-logos-social-links"]'),
+ ).toBeVisible();
});
});
diff --git a/knip.ts b/knip.ts
index e856d12..ca73b40 100644
--- a/knip.ts
+++ b/knip.ts
@@ -13,7 +13,6 @@ const config: KnipConfig = {
"@types/file-saver",
"eslint-config-next",
"@ianvs/prettier-plugin-sort-imports",
- "react-scan",
"pdfjs-dist",
],
ignore: [
@@ -22,7 +21,6 @@ const config: KnipConfig = {
"global.ts",
"src/i18n/**/*",
"src/app/schema/**/*",
- "src/**/dev/**/*",
"src/app/changelog/content/**/*",
"src/app/(app)/pdf-i18n-translations/pdf-translations.ts",
],
@@ -30,7 +28,7 @@ const config: KnipConfig = {
// ignore tags
// https://knip.dev/reference/configuration#tags
tags: ["-@lintignore"],
- ignoreBinaries: ["act", "zizmor", "printf"],
+ ignoreBinaries: ["act", "zizmor", "printf", "cloudflared"],
};
export default config;
diff --git a/messages/de.json b/messages/de.json
index e66a8a0..8f56ed0 100644
--- a/messages/de.json
+++ b/messages/de.json
@@ -71,7 +71,7 @@
"goToApp": "Öffnen",
"home": "Startseite",
"viewOnGithub": "Auf GitHub ansehen",
- "starOnGithub": "Auf GitHub bewerten",
+ "starOnGithub": "GitHub",
"switchLanguage": "Sprache wechseln",
"shareFeedback": "Feedback teilen",
"app": "App",
diff --git a/messages/es.json b/messages/es.json
index d339603..c6916b3 100644
--- a/messages/es.json
+++ b/messages/es.json
@@ -71,7 +71,7 @@
"goToApp": "Abrir",
"home": "Inicio",
"viewOnGithub": "Ver en GitHub",
- "starOnGithub": "Dar estrella en GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Cambiar idioma",
"shareFeedback": "Compartir comentarios",
"app": "Aplicación",
diff --git a/messages/fr.json b/messages/fr.json
index d8aca63..2da4bca 100644
--- a/messages/fr.json
+++ b/messages/fr.json
@@ -63,7 +63,7 @@
"goToApp": "Ouvrir",
"home": "Accueil",
"viewOnGithub": "Voir sur GitHub",
- "starOnGithub": "Mettre une étoile sur GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Changer de langue",
"shareFeedback": "Partager un avis",
"app": "Application",
diff --git a/messages/it.json b/messages/it.json
index df22a71..8540145 100644
--- a/messages/it.json
+++ b/messages/it.json
@@ -71,7 +71,7 @@
"goToApp": "Apri",
"home": "Home",
"viewOnGithub": "Visualizza su GitHub",
- "starOnGithub": "Metti una stella su GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Cambia lingua",
"shareFeedback": "Condividi feedback",
"app": "App",
diff --git a/messages/nl.json b/messages/nl.json
index 680f306..4de7ff3 100644
--- a/messages/nl.json
+++ b/messages/nl.json
@@ -71,7 +71,7 @@
"goToApp": "Open",
"home": "Startpagina",
"viewOnGithub": "Bekijk op GitHub",
- "starOnGithub": "Ster geven op GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Verander taal",
"shareFeedback": "Feedback delen",
"app": "App",
diff --git a/messages/pl.json b/messages/pl.json
index 45c5d47..c76d67a 100644
--- a/messages/pl.json
+++ b/messages/pl.json
@@ -71,7 +71,7 @@
"goToApp": "Otwórz",
"home": "Strona",
"viewOnGithub": "Zobacz na GitHub",
- "starOnGithub": "Oznacz gwiazdką na GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Zmień język",
"shareFeedback": "Podziel się opinią",
"app": "Aplikacja",
diff --git a/messages/pt.json b/messages/pt.json
index 13dff62..8635f25 100644
--- a/messages/pt.json
+++ b/messages/pt.json
@@ -71,7 +71,7 @@
"goToApp": "Abrir",
"home": "Página inicial",
"viewOnGithub": "Ver no GitHub",
- "starOnGithub": "Dar estrela no GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Mudar idioma",
"shareFeedback": "Compartilhar feedback",
"app": "App",
diff --git a/messages/ru.json b/messages/ru.json
index 4f6b336..dd21950 100644
--- a/messages/ru.json
+++ b/messages/ru.json
@@ -71,7 +71,7 @@
"goToApp": "Открыть",
"home": "Главная",
"viewOnGithub": "Посмотреть на GitHub",
- "starOnGithub": "Поставить звезду на GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Изменить язык",
"shareFeedback": "Поделиться отзывом",
"app": "Приложение",
diff --git a/messages/uk.json b/messages/uk.json
index ba1705c..6e6246d 100644
--- a/messages/uk.json
+++ b/messages/uk.json
@@ -71,7 +71,7 @@
"goToApp": "Відкрити",
"home": "Головна",
"viewOnGithub": "Переглянути на GitHub",
- "starOnGithub": "Поставити зірку на GitHub",
+ "starOnGithub": "GitHub",
"switchLanguage": "Змінити мову",
"shareFeedback": "Поділитися відгуком",
"app": "Додаток",
diff --git a/package.json b/package.json
index 48874b0..b1541cf 100644
--- a/package.json
+++ b/package.json
@@ -2,12 +2,10 @@
"name": "easy-invoice-pdf",
"version": "1.0.3",
"private": true,
- "packageManager": "[email protected]+sha512.3590e550d5384caa39bd5c7c739f72270234b2f6059e13018f975c313b1eb9fefcc09714048765d4d9efe961382c312e624572c0420762bdc5d5940cdf9be73a",
- "pnpm": {
- "minimumReleaseAge": 7200,
- "trustPolicy": "no-downgrade",
- "blockExoticSubdeps": true
- },
+ "packageManager": "[email protected]+sha512.1c67b3b359b2d408119ba1ed289f34b8fc3c6873412bec6fd264fbdc82489e510fcbecb9ce9d22dae7f3b76269d8441046014bdca53b9979cd7a561ad631b800",
+ "author": "Vlad Sazonau (https://vladsazon.com)",
+ "homepage": "https://easyinvoicepdf.com",
+ "description": "Free and open-source invoice generator.",
"scripts": {
"dev": "next dev",
"build": "next build",
@@ -26,15 +24,15 @@
"e2e:not-flaky": "pnpm e2e --workers=2",
"e2e:update-snapshots": "pnpm e2e --update-snapshots",
"dedupe": "pnpm dedupe",
- "lint-stage": "pnpm dlx lint-staged --verbose",
+ "lint-stage": "pnpm lint-staged --verbose",
"check-meta": "pnpx check-site-meta",
"dev:email": "email dev --dir src/emails",
"prepare": "husky",
- "expose-to-internet": "pnpm dlx cloudflared tunnel --url http://localhost:3000",
- "cloudflared:tunnel": "pnpm dlx cloudflared tunnel run easy-invoice-pdf-local-dev",
+ "expose-to-internet": "cloudflared tunnel --url http://localhost:3000",
+ "cloudflared:tunnel": "cloudflared tunnel run easy-invoice-pdf-local-dev",
"corepack:enable": "corepack enable",
"corepack:prepare": "corepack prepare pnpm@latest",
- "update-github-actions": "pnpm dlx actions-up --min-age=7",
+ "update-github-actions": "pnpm actions-up --min-age=7",
"test-gh-action-locally:monthly-recurring-invoice": "act schedule -j recurring-invoice --secret-file .github/workflows/.secrets"
},
"dependencies": {
@@ -97,13 +95,13 @@
"devDependencies": {
"@eslint/eslintrc": "3.3.1",
"@next/eslint-plugin-next": "15.2.3",
- "@playwright/test": "1.56.1",
+ "@playwright/test": "1.60.0",
"@types/file-saver": "2.0.7",
"@types/node": "22.8.1",
"@types/react": "18.3.12",
"@types/react-dom": "18.3.1",
"@typescript/native-preview": "7.0.0-dev.20260217.1",
- "actions-up": "1.12.0",
+ "actions-up": "1.14.2",
"autoprefixer": "10.4.21",
"dotenv": "17.2.3",
"eslint": "9.33.0",
@@ -117,12 +115,23 @@
"prettier": "3.5.3",
"prettier-plugin-tailwindcss": "0.6.11",
"react-email": "4.0.4",
- "react-scan": "0.3.4",
"schema-dts": "1.1.5",
"shadcn": "3.2.1",
"tailwindcss": "3.4.14",
"typescript": "5.9.3",
"typescript-eslint": "8.56.0",
"vitest": "3.2.4"
- }
+ },
+ "keywords": [
+ "invoice",
+ "pdf",
+ "invoice generator",
+ "open source",
+ "free",
+ "invoice pdf",
+ "professional invoice",
+ "online invoice",
+ "pdf invoice template",
+ "easyinvoicepdf"
+ ]
}
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 331fbcb..0e5f5ba 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -58,7 +58,7 @@ importers:
version: 4.3.0([email protected])
'@sentry/nextjs':
specifier: 9.3.0
- version: 9.3.0(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected](@babel/[email protected])(@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected]))([email protected])([email protected])
+ version: 9.3.0(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected](@babel/[email protected])(@opentelemetry/[email protected])(@playwright/[email protected])([email protected]([email protected]))([email protected]))([email protected])([email protected])
'@t3-oss/env-nextjs':
specifier: 0.13.4
@@ -85,7 +85,7 @@ importers:
version: 3.5.1
'@vercel/speed-insights':
specifier: 1.2.0
class-variance-authority:
specifier: 0.7.1
version: 0.7.1
@@ -127,10 +127,10 @@ importers:
version: 1.21.0
next:
specifier: 14.2.15
next-intl:
specifier: 4.0.2
qrcode:
specifier: 1.5.4
version: 1.5.4
@@ -181,8 +181,8 @@ importers:
specifier: 15.2.3
version: 15.2.3
'@playwright/test':
- specifier: 1.56.1
- version: 1.56.1
+ specifier: 1.60.0
+ version: 1.60.0
'@types/file-saver':
specifier: 2.0.7
version: 2.0.7
@@ -199,8 +199,8 @@ importers:
specifier: 7.0.0-dev.20260217.1
version: 7.0.0-dev.20260217.1
actions-up:
- specifier: 1.12.0
- version: 1.12.0
+ specifier: 1.14.2
+ version: 1.14.2
autoprefixer:
specifier: 10.4.21
version: 10.4.21([email protected])
@@ -239,10 +239,7 @@ importers:
version: 0.6.11([email protected])
react-email:
specifier: 4.0.4
- react-scan:
- specifier: 0.3.4
schema-dts:
specifier: 1.1.5
version: 1.1.5
@@ -260,7 +257,7 @@ importers:
vitest:
specifier: 3.2.4
packages:
@@ -475,12 +472,6 @@ packages:
'@bundled-es-modules/[email protected]':
resolution: {integrity: sha512-yn7BklA5acgcBr+7w064fGV+SGIFySjCKpqjcWgBAIfrAkY+4GQTJJHQMeT3V/sgz23VTEVV8TtOmkvJAhFVfg==}
- '@clack/[email protected]':
- resolution: {integrity: sha512-5cfhQNH+1VQ2xLQlmzXMqUoiaH0lRBq9/CLW9lTyMbuKLC3+xEK01tHVvyut++mLOn5urSHmkm6I0Lg9MaJSTQ==}
-
- '@clack/[email protected]':
- resolution: {integrity: sha512-6b9Ab2UiZwJYA9iMyboYyW9yJvAO9V753ZhS+DHKEjZRKAxPPOb7MXXu84lsPFG+vZt6FRFniZ8rXi+zCIw4yQ==}
-
'@dotenvx/[email protected]':
resolution: {integrity: sha512-M1cyP6YstFQCjih54SAxCqHLMMi8QqV8tenpgGE48RTXWD7vfMYJiw/6xcCDpS2h28AcLpTsFCZA863Ge9yxzA==}
hasBin: true
@@ -1441,29 +1432,15 @@ packages:
cpu: [x64]
os: [win32]
- '@pivanov/[email protected]':
- resolution: {integrity: sha512-q9CN0bFWxWgMY5hVVYyBgez1jGiLBa6I+LkG37ycylPhFvEGOOeaADGtUSu46CaZasPnlY8fCdVJZmrgKb1EPA==}
- peerDependencies:
- react: '>=18'
- react-dom: '>=18'
-
resolution: {integrity: sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==}
engines: {node: '>=14'}
- '@playwright/[email protected]':
- resolution: {integrity: sha512-vSMYtL/zOcFpvJCW71Q/OEGQb7KYBPAdKh35WNSkaZA75JlAO8ED8UN6GUNTm3drWomcbcqRPFqQbLae8yBTdg==}
+ '@playwright/[email protected]':
+ resolution: {integrity: sha512-O71yZIbAh/PxDMNGns37GHBIfrVkEVyn+AXyIa5dOTfb4/xNvRWV+Vv/NMbNCtODB/pO7vLlF2OTmMVLhmr7Ag==}
engines: {node: '>=18'}
hasBin: true
- '@preact/[email protected]':
- resolution: {integrity: sha512-OBvUsRZqNmjzCZXWLxkZfhcgT+Fk8DDcT/8vD6a1xhDemodyy87UJRJfASMuSD8FaAIeGgGm85ydXhm7lr4fyA==}
-
- '@preact/[email protected]':
- resolution: {integrity: sha512-naxcJgUJ6BTOROJ7C3QML7KvwKwCXQJYTc5L/b0eEsdYgPB6SxwoQ1vDGcS0Q7GVjAenVq/tXrybVdFShHYZWg==}
- peerDependencies:
- preact: 10.x
-
'@prisma/[email protected]':
resolution: {integrity: sha512-1SeN0IvMp5zm3RLJnEr+Zn67WDqUIPP1lF/PkLbi/X64vsnFyItcXNRBrYr0/sI2qLcH9iNzJUhyd3emdGizaQ==}
peerDependencies:
@@ -2468,9 +2445,6 @@ packages:
resolution: {integrity: sha512-8nneRWKCg3rMtF69nLQJnOYUcbafYeFSjqkw3jCRLsqkWFlHaoQrr5mXmofFGOx3DKn7UfmBMyov8ySvLRVldA==}
- '@types/[email protected]':
- resolution: {integrity: sha512-Mxiq0ULv/zo1OzOhwPqOA13I81CV/W3nvd3ChtQZRT5Cwz3cr0FKo/wMSsbTqL3EXpaBAEQhva2B8ByRkOIh9A==}
-
resolution: {integrity: sha512-k6Gi8Yyo8EtrNtkHXutUu2corfDf9su95VYVP10aGYMMROM6SAItZi0w1XszA6RtWTHSVp5OeFof37w0IEqCQg==}
@@ -2489,11 +2463,6 @@ packages:
resolution: {integrity: sha512-qW1Mfv8taImTthu4KoXgDfLuk4bydU6Q/TkADnDWWHwi4NX4BR+LWfTp2sVmTqRrsHvyDDTelgelxJ+SsejKKQ==}
- '@types/[email protected]':
- resolution: {integrity: sha512-HHM3nxyUZ3zAylX8ZEyrDNd2XZOnQ0D5XfunJF5FLQnZbHHYq4UWvW1QfelQNXv1ICNkwYhfxjwfnqivYB6bFg==}
- peerDependencies:
- '@types/react': '*'
-
resolution: {integrity: sha512-D2wOSq/d6Agt28q7rSI3jhU7G6aiuzljDGZ2hTZHIkrTLUI+AF3WMeKkEZ9nN2fkBAlcktT6vcZjDFiIhMYEQw==}
@@ -2932,8 +2901,8 @@ packages:
engines: {node: '>=0.4.0'}
hasBin: true
- resolution: {integrity: sha512-EFAv3XX3gfjfWhy5e6Kw1PpC0DrTSuK4e77xoS27hqcrjf92C+yCs05tIsBPGFZv8+EichF8HMTtimuMj2sv+A==}
+ resolution: {integrity: sha512-yQHZAU4UkWegGY2vmgg1TYAoKQDFPX5NUAI57P0BXhgB6wDGBNVhgBuXUkid8mxVviF8OMVr4yxMvax2nnY0Cw==}
engines: {node: ^18.0.0 || >=20.0.0}
hasBin: true
@@ -3120,11 +3089,6 @@ packages:
resolution: {integrity: sha512-Ceh+7ox5qe7LJuLHoY0feh3pHuUDHAcRUeyL2VYghZwfpkNIy/+8Ocg0a3UuSoYzavmylwuLWQOf3hl0jjMMIw==}
engines: {node: '>=8'}
- resolution: {integrity: sha512-lg8i4YjVBcAsF8mKVaWjbgG/yo1fY9SUbGgilsnkOnLyU37Jj0XDLWTBeuZjFrrd6LNf1od8/tO/soIi2KUTrw==}
- peerDependencies:
- react: '>=17.0.1'
-
resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==}
@@ -3174,6 +3138,10 @@ packages:
resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==}
engines: {node: '>=8'}
+ resolution: {integrity: sha512-tixWYgm5ZoOD+3g6UTea91eow5z6AAHaho3g0V9CNSNb45gM8SmflpAc+GRd1InC4AqN/07Unrgp56Y94N9hJQ==}
+ engines: {node: '>=20.19.0'}
+
resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==}
engines: {node: '>= 0.4'}
@@ -5101,10 +5069,6 @@ packages:
react-dom:
optional: true
- resolution: {integrity: sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==}
- engines: {node: '>=4'}
-
resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==}
@@ -5482,23 +5446,13 @@ packages:
resolution: {integrity: sha512-ueGLflrrnvwB3xuo/uGob5pd5FN7l0MsLf0Z87o/UQmRtwjvfylfc9MurIxRAWywCYTgrvpXBcqjV4OfCYGCIQ==}
engines: {node: '>=16.20.0'}
- resolution: {integrity: sha512-l2osTgLXSMeuLZOML9qYODUQoPPnUsKsb5/P6LJ2e6uPKXUdPK5WYhN4z03G+YNbWmGDY4YENauNu4ZKczreHg==}
- engines: {node: '>=18'}
- hasBin: true
-
- resolution: {integrity: sha512-hutraynyn31F+Bifme+Ps9Vq59hKuUCz7H1kDOcBs+2oGguKkWTU50bBWrtz34OUWmIwpBTWDxaRPXrIXkgvmQ==}
- engines: {node: '>=18'}
- hasBin: true
-
- resolution: {integrity: sha512-JAwMNMBlxJ2oD1kce4KPtMkDeKGHQstdpFPcPH3maElAXon/QZeTvtsfXmTMRyO9TslfoYOXkSsvao2nE1ilTw==}
+ resolution: {integrity: sha512-9bW6zvX/m0lEbgTKJ6YppOKx8H3VOPBMOCFh2irXFOT4BbHgrx5hPjwJYLT40Lu+4qtD36qKc/Hn56StUW57IA==}
engines: {node: '>=18'}
hasBin: true
- resolution: {integrity: sha512-aFi5B0WovBHTEvpM3DzXTUaeN6eN0qWnTkKx4NQaH4Wvcmc153PdaY2UBdSYKaGYw+UyWXSVyxDUg5DoPEttjw==}
+ resolution: {integrity: sha512-hheHdokM8cdqCb0lcE3s+zT4t4W+vvjpGxsZlDnikarzx8tSzMebh3UiFtgqwFwnTnjYQcsyMF8ei2mCO/tpeA==}
engines: {node: '>=18'}
hasBin: true
@@ -5579,9 +5533,6 @@ packages:
resolution: {integrity: sha512-9ZhXKM/rw350N1ovuWHbGxnGh/SNJ4cnxHiM0rxE4VN41wsg8P8zWn9hv/buK00RP4WvlOyr/RBDiptyxVbkZQ==}
engines: {node: '>=0.10.0'}
- resolution: {integrity: sha512-5SRRBinwpwkaD+OqlBDeITlRgvd8I8QlxHJw9AxSdMNV6O+LodN9nUyYGpSF7sadHjs6RzeFShMexC6DbtWr9g==}
-
resolution: {integrity: sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==}
engines: {node: '>=10'}
@@ -5792,26 +5743,6 @@ packages:
'@types/react':
optional: true
- resolution: {integrity: sha512-jUkgs+sfK1B7T1jvZ0rQmKZtvUUE7cHB6qDTfCfOTmTJYH2aAFB1fGmE4DXBbQ1kUF+AdjyNT0Lc73LL/dQIbg==}
- hasBin: true
- peerDependencies:
- '@remix-run/react': '>=1.0.0'
- next: '>=13.0.0'
- react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
- react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
- react-router: ^5.0.0 || ^6.0.0 || ^7.0.0
- react-router-dom: ^5.0.0 || ^6.0.0 || ^7.0.0
- peerDependenciesMeta:
- '@remix-run/react':
- optional: true
- next:
- optional: true
- react-router:
- optional: true
- react-router-dom:
- optional: true
-
resolution: {integrity: sha512-b6jSvxvVnyptAiLjbkWLE/lOnR4lfTtDAl+eUC7RZy+QQWc6wRzIV2CE6xBuMmDxc2qIihtDCZD5NPOFl7fRBQ==}
engines: {node: '>=10'}
@@ -6009,6 +5940,11 @@ packages:
engines: {node: '>=10'}
hasBin: true
+ resolution: {integrity: sha512-rkVq3IXh+4FDGch+KwzX3aV9W3kO54GyEgpvBzSyctDA6Xtd7RJQV1xmXbeQp5v7+VzLOfVqiutSE6GICgPFvg==}
+ engines: {node: '>=10'}
+ hasBin: true
+
resolution: {integrity: sha512-uaW0WwXKpL9blXE2o0bRhoL2EGXIrZxQ2ZQ4mgcfoBxdFmQold+qWsD2jLrfZ0trjKL6vOw0j//eAwcALFjKSw==}
engines: {node: '>= 18'}
@@ -6583,10 +6519,6 @@ packages:
resolution: {integrity: sha512-aqrHaVBWW1JVKBHmGo33T5TxeL0qWzfvjWokObHA9bYmN7eNDkwOxmLjhioHl9878qDFMAaT51XNroRyuz7WxA==}
- resolution: {integrity: sha512-us4j03/499KhbGP8BU7Hrzrgseo+KdfJYWcbcajCOqsAyb8Gk0Yn2kiUIcZISYCb1JFaZfIuG3b42HmguVOKCQ==}
- engines: {node: '>=18.12.0'}
-
resolution: {integrity: sha512-bSjt9pjaEBnNiGgc9rUiHGKv5l4/TGzDmYw3RhnkJGtLhbnnA/5qJj7x3dNDCRx/PJxu774LlH8lCOlB4hEfKg==}
@@ -6755,9 +6687,6 @@ packages:
resolution: {integrity: sha512-kyDivFZ7ZM0BVOUteVbDFhlRt7Ah/CSPwJdi8hBpkK7QLumUqdLtVfm/PX/hkcnrvr0i77fO5+TjZ94Pe+C9iw==}
- resolution: {integrity: sha512-66/V2i5hQanC51vBQKPH4aI8NMAcBW59FVBs+rC7eGHupMyfn34q7rZIE+ETlJ+XTevqfUhVVBgSUNSW2flEUQ==}
-
resolution: {integrity: sha512-UFynvx+gM44Gv9qFgj0acCQK2VE1CtdfwFdimkapco3hlPCJ/zeq73n2yVKimVbtm+TnApIugGhLJnkU6gjYXA==}
engines: {node: '>=10.13.0'}
@@ -6864,6 +6793,11 @@ packages:
engines: {node: '>= 14.6'}
hasBin: true
+ resolution: {integrity: sha512-2AvhNX3mb8zd6Zy7INTtSpl1F15HW6Wnqj0srWlkKLcpYl/gMIMJiyuGq2KeI2YFxUPjdlB+3Lc10seMLtL4cA==}
+ engines: {node: '>= 14.6'}
+ hasBin: true
+
resolution: {integrity: sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ==}
engines: {node: '>=6'}
@@ -7219,17 +7153,6 @@ snapshots:
dependencies:
statuses: 2.0.2
- '@clack/[email protected]':
- dependencies:
- picocolors: 1.1.1
- sisteransi: 1.0.5
-
- '@clack/[email protected]':
- dependencies:
- '@clack/core': 0.3.5
- picocolors: 1.1.1
- sisteransi: 1.0.5
-
'@dotenvx/[email protected]':
dependencies:
commander: 11.1.0
@@ -8099,24 +8022,12 @@ snapshots:
'@oxc-resolver/[email protected]':
optional: true
- dependencies:
- react: 18.3.1
- react-dom: 18.3.1([email protected])
-
optional: true
- '@playwright/[email protected]':
- dependencies:
- playwright: 1.56.1
-
- '@preact/[email protected]': {}
-
+ '@playwright/[email protected]':
dependencies:
- '@preact/signals-core': 1.8.0
- preact: 10.26.6
+ playwright: 1.60.0
'@prisma/[email protected](@opentelemetry/[email protected])':
dependencies:
@@ -8970,7 +8881,7 @@ snapshots:
'@sentry/[email protected]': {}
dependencies:
'@opentelemetry/api': 1.9.0
'@opentelemetry/semantic-conventions': 1.30.0
@@ -8983,7 +8894,7 @@ snapshots:
'@sentry/vercel-edge': 9.3.0
'@sentry/webpack-plugin': 3.1.2([email protected])
chalk: 3.0.0
resolve: 1.22.8
rollup: 3.29.5
stacktrace-parser: 0.1.11
@@ -9188,10 +9099,6 @@ snapshots:
'@types/node': 22.8.1
form-data: 4.0.2
- '@types/[email protected]':
- dependencies:
- undici-types: 6.19.8
-
dependencies:
undici-types: 6.19.8
@@ -9216,10 +9123,6 @@ snapshots:
dependencies:
'@types/react': 18.3.12
- dependencies:
- '@types/react': 18.3.12
-
dependencies:
'@types/prop-types': 15.7.13
@@ -9534,9 +9437,9 @@ snapshots:
'@vercel/[email protected]': {}
optionalDependencies:
react: 18.3.1
'@vitest/[email protected]':
@@ -9547,14 +9450,14 @@ snapshots:
chai: 5.2.1
tinyrainbow: 2.0.0
dependencies:
'@vitest/spy': 3.2.4
estree-walker: 3.0.3
magic-string: 0.30.17
optionalDependencies:
'@vitest/[email protected]':
dependencies:
@@ -9684,14 +9587,14 @@ snapshots:
dependencies:
- cac: 6.7.14
+ cac: 7.0.0
enquirer: 2.4.1
nanospinner: 1.2.2
picocolors: 1.1.1
- semver: 7.7.4
- yaml: 2.8.3
+ semver: 7.8.1
+ yaml: 2.9.0
dependencies:
@@ -9885,13 +9788,6 @@ snapshots:
- dependencies:
- '@types/react-reconciler': 0.28.9(@types/[email protected])
- react: 18.3.1
- transitivePeerDependencies:
- - '@types/react'
-
dependencies:
buffer: 5.7.1
@@ -9957,6 +9853,8 @@ snapshots:
+
dependencies:
es-errors: 1.3.0
@@ -12352,8 +12250,6 @@ snapshots:
react: 18.3.1
react-dom: 18.3.1([email protected])
-
@@ -12410,17 +12306,17 @@ snapshots:
dependencies:
'@formatjs/intl-localematcher': 0.5.10
negotiator: 1.0.0
react: 18.3.1
use-intl: 4.0.2([email protected])
optionalDependencies:
typescript: 5.9.3
dependencies:
'@next/env': 14.2.15
'@swc/helpers': 0.5.5
@@ -12430,7 +12326,7 @@ snapshots:
postcss: 8.4.31
react: 18.3.1
react-dom: 18.3.1([email protected])
- styled-jsx: 5.1.1(@babel/[email protected])([email protected])
+ styled-jsx: 5.1.1(@babel/[email protected])([email protected])
optionalDependencies:
'@next/swc-darwin-arm64': 14.2.15
'@next/swc-darwin-x64': 14.2.15
@@ -12442,12 +12338,12 @@ snapshots:
'@next/swc-win32-ia32-msvc': 14.2.15
'@next/swc-win32-x64-msvc': 14.2.15
'@opentelemetry/api': 1.9.0
- '@playwright/test': 1.56.1
+ '@playwright/test': 1.60.0
transitivePeerDependencies:
- '@babel/core'
- babel-plugin-macros
dependencies:
'@next/env': 15.2.3
'@swc/counter': 0.1.3
@@ -12457,7 +12353,7 @@ snapshots:
postcss: 8.4.31
react: 18.3.1
react-dom: 18.3.1([email protected])
- styled-jsx: 5.1.6(@babel/[email protected])([email protected])
+ styled-jsx: 5.1.6(@babel/[email protected])([email protected])
optionalDependencies:
'@next/swc-darwin-arm64': 15.2.3
'@next/swc-darwin-x64': 15.2.3
@@ -12468,7 +12364,7 @@ snapshots:
'@next/swc-win32-arm64-msvc': 15.2.3
'@next/swc-win32-x64-msvc': 15.2.3
'@opentelemetry/api': 1.9.0
- '@playwright/test': 1.56.1
+ '@playwright/test': 1.60.0
sharp: 0.33.5
transitivePeerDependencies:
- '@babel/core'
@@ -12764,19 +12660,11 @@ snapshots:
-
-
- dependencies:
- playwright-core: 1.52.0
- optionalDependencies:
- fsevents: 2.3.2
dependencies:
- playwright-core: 1.56.1
+ playwright-core: 1.60.0
optionalDependencies:
fsevents: 2.3.2
@@ -12799,7 +12687,7 @@ snapshots:
dependencies:
lilconfig: 3.1.3
- yaml: 2.7.0
+ yaml: 2.8.3
optionalDependencies:
postcss: 8.5.3
@@ -12848,8 +12736,6 @@ snapshots:
dependencies:
xtend: 4.0.2
-
dependencies:
detect-libc: 2.0.3
@@ -12955,7 +12841,7 @@ snapshots:
react: 18.3.1
scheduler: 0.23.2
dependencies:
'@babel/parser': 7.24.5
'@babel/traverse': 7.25.6
@@ -12967,7 +12853,7 @@ snapshots:
glob: 10.3.4
log-symbols: 4.1.0
mime-types: 2.1.35
normalize-path: 3.0.0
ora: 5.4.1
socket.io: 4.8.1
@@ -13045,35 +12931,6 @@ snapshots:
optionalDependencies:
'@types/react': 18.3.12
- dependencies:
- '@babel/core': 7.26.9
- '@babel/generator': 7.26.9
- '@babel/types': 7.26.9
- '@clack/core': 0.3.5
- '@clack/prompts': 0.8.2
- '@preact/signals': 1.3.2([email protected])
- '@rollup/pluginutils': 5.1.4([email protected])
- '@types/node': 20.17.50
- bippy: 0.3.14(@types/[email protected])([email protected])
- esbuild: 0.25.0
- estree-walker: 3.0.3
- kleur: 4.1.5
- mri: 1.2.0
- playwright: 1.52.0
- preact: 10.26.6
- react: 18.3.1
- react-dom: 18.3.1([email protected])
- tsx: 4.19.4
- optionalDependencies:
- unplugin: 2.1.0
- transitivePeerDependencies:
- - '@types/react'
- - rollup
- - supports-color
-
dependencies:
get-nonce: 1.0.1
@@ -13372,6 +13229,8 @@ snapshots:
+
dependencies:
debug: 4.4.1
@@ -13759,19 +13618,19 @@ snapshots:
dependencies:
inline-style-parser: 0.2.4
dependencies:
client-only: 0.0.1
react: 18.3.1
optionalDependencies:
- '@babel/core': 7.28.3
+ '@babel/core': 7.26.9
dependencies:
client-only: 0.0.1
react: 18.3.1
optionalDependencies:
- '@babel/core': 7.28.3
+ '@babel/core': 7.26.9
dependencies:
@@ -13955,6 +13814,7 @@ snapshots:
get-tsconfig: 4.10.1
optionalDependencies:
fsevents: 2.3.3
+ optional: true
dependencies:
@@ -14106,12 +13966,6 @@ snapshots:
webpack-sources: 3.3.3
webpack-virtual-modules: 0.5.0
- dependencies:
- acorn: 8.15.0
- webpack-virtual-modules: 0.6.2
- optional: true
-
dependencies:
napi-postinstall: 0.3.3
@@ -14196,13 +14050,13 @@ snapshots:
string_decoder: 1.3.0
util-deprecate: 1.0.2
dependencies:
cac: 6.7.14
debug: 4.4.1
es-module-lexer: 1.7.0
pathe: 2.0.3
transitivePeerDependencies:
- '@types/node'
- jiti
@@ -14217,7 +14071,7 @@ snapshots:
- tsx
- yaml
dependencies:
esbuild: 0.25.0
fdir: 6.4.4([email protected])
@@ -14231,13 +14085,13 @@ snapshots:
jiti: 2.4.2
terser: 5.43.1
tsx: 4.19.4
- yaml: 2.8.3
+ yaml: 2.9.0
dependencies:
'@types/chai': 5.2.2
'@vitest/expect': 3.2.4
'@vitest/pretty-format': 3.2.4
'@vitest/runner': 3.2.4
'@vitest/snapshot': 3.2.4
@@ -14255,8 +14109,8 @@ snapshots:
tinyglobby: 0.2.14
tinypool: 1.1.1
tinyrainbow: 2.0.0
why-is-node-running: 2.3.0
optionalDependencies:
'@types/debug': 4.1.12
@@ -14298,9 +14152,6 @@ snapshots:
- optional: true
-
dependencies:
'@types/eslint-scope': 3.7.7
@@ -14434,6 +14285,8 @@ snapshots:
+
dependencies:
camelcase: 5.3.1
diff --git a/src/app/(components)/footer.tsx b/src/app/(components)/footer.tsx
index 523fb75..2dffbe7 100644
--- a/src/app/(components)/footer.tsx
+++ b/src/app/(components)/footer.tsx
@@ -168,10 +168,7 @@ function DefaultFooterLinks() {
return (
<ul className="space-y-2">
<li>
- <Link
- href="/?template=default"
- className="text-sm text-slate-500 hover:text-slate-900"
- >
+ <Link href="/" className="text-sm text-slate-500 hover:text-slate-900">
Invoice Generator
</Link>
</li>
diff --git a/src/app/(components)/header/header.client.tsx b/src/app/(components)/header/header.client.tsx
index 072531e..1839fd5 100644
--- a/src/app/(components)/header/header.client.tsx
+++ b/src/app/(components)/header/header.client.tsx
@@ -26,11 +26,16 @@ const desktopNavLinkClass =
* @param githubStarsCount - Number of GitHub stars to display
*/
export function HeaderClient({
- locale,
- translations,
- hideLanguageSwitcher = false,
+ locale = "en",
+ translations = defaultTranslations,
+ hideLanguageSwitcher = true,
githubStarsCount,
-}: HeaderProps & { githubStarsCount: number }) {
+}: Omit<HeaderProps, "translations" | "locale" | "hideLanguageSwitcher"> & {
+ locale?: HeaderProps["locale"];
+ translations?: HeaderProps["translations"];
+ hideLanguageSwitcher?: HeaderProps["hideLanguageSwitcher"];
+ githubStarsCount: number;
+}) {
const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false);
const gitHubStarCountFormatted = githubStarCountFormatter
@@ -149,3 +154,19 @@ export function HeaderClient({
</header>
);
}
+
+const defaultTranslations = {
+ navLinks: {
+ home: "Home",
+ features: "Features",
+ faq: "FAQ",
+ github: "GitHub",
+ githubCTA: "Star on GitHub",
+ tagline: "Free & Open-Source Invoice Generator",
+ },
+ switchLanguageText: "Switch Language",
+ goToAppText: "Open app",
+ startInvoicingButtonText: "Start Invoicing",
+ changelogLinkText: "Changelog",
+ termsOfServiceLinkText: "Terms of Service",
+} as const satisfies HeaderProps["translations"];
diff --git a/src/app/(components)/header/index.tsx b/src/app/(components)/header/index.tsx
index 09217c2..04187ef 100644
--- a/src/app/(components)/header/index.tsx
+++ b/src/app/(components)/header/index.tsx
@@ -30,7 +30,16 @@ export interface HeaderProps {
* @param props.hideLanguageSwitcher - Optional flag to hide language switcher
* @returns Rendered header with GitHub stars count
*/
-export async function Header(props: HeaderProps) {
+export async function Header(
+ props: Omit<
+ HeaderProps,
+ "translations" | "locale" | "hideLanguageSwitcher"
+ > & {
+ translations?: HeaderProps["translations"];
+ locale?: HeaderProps["locale"];
+ hideLanguageSwitcher?: HeaderProps["hideLanguageSwitcher"];
+ },
+) {
const githubStarsCount = await fetchGithubStars();
return <HeaderClient {...props} githubStarsCount={githubStarsCount} />;
diff --git a/src/app/(components)/header/mobile-menu.tsx b/src/app/(components)/header/mobile-menu.tsx
index a141483..7139ca8 100644
--- a/src/app/(components)/header/mobile-menu.tsx
+++ b/src/app/(components)/header/mobile-menu.tsx
@@ -44,7 +44,7 @@ export function MobileMenuPanel({
locale,
translations,
hideLanguageSwitcher,
- githubStarsCount,
+ githubStarsCount = 0,
}: MobileMenuPanelProps) {
const pathname = usePathname();
const titleId = useId();
@@ -153,7 +153,7 @@ export function MobileMenuPanel({
)}
</a>
- <div className="w-full pt-4">
+ <div className="w-full pb-2 pt-4">
<Button
size="lg"
variant="outline"
@@ -180,7 +180,7 @@ export function MobileMenuPanel({
{!hideLanguageSwitcher ? (
<div className="border-t border-slate-200 px-6 pb-6 pt-5 sm:px-8 md:px-12 md:pb-8 md:pt-6">
<div className="flex items-center gap-2 px-2">
- <span className="text-sm text-slate-700">
+ <span className="text-sm text-slate-800">
{translations.switchLanguageText}
</span>
<LanguageSwitcher
diff --git a/src/app/(seo-landings)/components/seo-landing-shell.tsx b/src/app/(seo-landings)/components/seo-landing-shell.tsx
index 64b60d3..81e75b9 100644
--- a/src/app/(seo-landings)/components/seo-landing-shell.tsx
+++ b/src/app/(seo-landings)/components/seo-landing-shell.tsx
@@ -9,9 +9,9 @@ import {
type SeoLandingDefinition,
type SeoSection,
} from "../seo-landing-definitions";
-import { PlusIcon } from "lucide-react";
import { StickySeoCta } from "@/app/(seo-landings)/components/sticky-seo-cta";
import { Button } from "@/components/ui/button";
+import { FaqAccordion, FaqAccordionItem } from "@/components/ui/faq-accordion";
import { GithubIcon } from "@/components/etc/github-logo";
import { Header } from "@/app/(components)/header";
@@ -34,24 +34,7 @@ export function SeoLandingShell({ definition }: SeoLandingShellProps) {
<SeoLandingJsonLd definition={definition} />
<div className="flex min-h-screen flex-col bg-slate-50">
- <Header
- locale="en"
- translations={{
- navLinks: {
- home: "Home",
- features: "Features",
- faq: "FAQ",
- github: "GitHub",
- githubCTA: "Star on GitHub",
- tagline: "Free & Open-Source Invoice Generator",
- },
- switchLanguageText: "Switch language",
- goToAppText: "Open app",
- startInvoicingButtonText: "Start Invoicing",
- changelogLinkText: "Changelog",
- termsOfServiceLinkText: "Terms of Service",
- }}
- />
+ <Header />
<main className="flex flex-1 flex-col md:pb-12">
<div className="border-b border-slate-200 bg-white">
<div className="container mx-auto max-w-4xl px-4 pb-6 pt-12 md:px-6 md:py-16 md:pb-8">
@@ -150,31 +133,16 @@ export function SeoLandingShell({ definition }: SeoLandingShellProps) {
>
FAQ
</h2>
- <div className="space-y-2">
+ <FaqAccordion>
{definition.faq.map((item) => (
- <details
+ <FaqAccordionItem
key={item.question}
- className="group cursor-pointer border-b border-dashed border-stone-300 transition-all duration-200 last:border-b-0"
+ question={item.question}
>
- <summary className="flex select-none items-center justify-between gap-2 py-3 text-left">
- <h3 className="text-base font-medium text-stone-900">
- {item.question}
- </h3>
- <PlusIcon
- className="ml-auto size-6 shrink-0 rounded-full p-1 text-stone-400 transition-all duration-200 hover:bg-stone-200/50 group-open:rotate-45 group-hover:text-stone-900"
- aria-hidden="true"
- />
- </summary>
- <div className="overflow-hidden">
- <div className="pb-4 pr-4">
- <p className="cursor-default text-pretty text-sm leading-relaxed text-stone-600">
- {item.answer}
- </p>
- </div>
- </div>
- </details>
+ {item.answer}
+ </FaqAccordionItem>
))}
- </div>
+ </FaqAccordion>
</section>
<div className="flex justify-center py-6 md:py-12">
diff --git a/src/app/[locale]/about/page.tsx b/src/app/[locale]/about/page.tsx
index 56d9be7..43969cd 100644
--- a/src/app/[locale]/about/page.tsx
+++ b/src/app/[locale]/about/page.tsx
@@ -5,6 +5,7 @@ import {
GoToAppButton,
} from "@/app/(components)/header/go-to-app-button-cta";
import { Button } from "@/components/ui/button";
+import { FaqAccordion, FaqAccordionItem } from "@/components/ui/faq-accordion";
import { TooltipProvider } from "@/components/ui/tooltip";
import { AutoPlayVideo, ManualPlayVideo } from "@/components/video";
@@ -15,7 +16,6 @@ import {
VIDEO_DEMO_URL,
} from "@/config";
import { routing } from "@/i18n/routing";
-import { PlusIcon } from "lucide-react";
import { useTranslations, type Locale } from "next-intl";
import { setRequestLocale } from "next-intl/server";
import Link from "next/link";
@@ -41,7 +41,7 @@ export default function AboutPage({ params }: { params: { locale: Locale } }) {
features: t("footer.links.features"),
faq: "FAQ",
github: t("footer.links.github"),
- githubCTA: t("buttons.viewOnGithub"),
+ githubCTA: t("buttons.starOnGithub"),
tagline: t("tagline"),
} as const satisfies HeaderProps["translations"]["navLinks"];
@@ -67,6 +67,7 @@ export default function AboutPage({ params }: { params: { locale: Locale } }) {
changelogLinkText,
termsOfServiceLinkText,
}}
+ hideLanguageSwitcher={false}
/>
<main>
@@ -425,36 +426,17 @@ function FaqSection() {
</div>
</div>
<div className="mx-auto mt-14 max-w-3xl">
- <div className="space-y-2">
- {ABOUT_FAQ_ITEM_KEYS.map((translationKey) => {
- const question = t(`items.${translationKey}.question`);
- const answer = t(`items.${translationKey}.answer`);
-
- return (
- <details
- key={translationKey}
- className="group cursor-pointer border-b border-dashed border-stone-300 bg-white transition-all duration-200 last:border-b-0"
- >
- <summary className="flex select-none items-center justify-between gap-2 py-3 text-left">
- <h3 className="text-base font-medium text-stone-900">
- {question}
- </h3>
- <PlusIcon
- className="ml-auto size-6 shrink-0 rounded-full p-1 text-stone-400 transition-all duration-200 hover:bg-stone-200/50 group-open:rotate-45 group-hover:text-stone-900"
- aria-hidden="true"
- />
- </summary>
- <div className="overflow-hidden">
- <div className="pb-4 pr-4">
- <p className="cursor-default text-pretty text-sm leading-relaxed text-stone-600">
- {answer}
- </p>
- </div>
- </div>
- </details>
- );
- })}
- </div>
+ <FaqAccordion>
+ {ABOUT_FAQ_ITEM_KEYS.map((translationKey) => (
+ <FaqAccordionItem
+ key={translationKey}
+ question={t(`items.${translationKey}.question`)}
+ className="border-stone-300 bg-white"
+ >
+ {t(`items.${translationKey}.answer`)}
+ </FaqAccordionItem>
+ ))}
+ </FaqAccordion>
</div>
</div>
</section>
diff --git a/src/app/changelog/[slug]/page.tsx b/src/app/changelog/[slug]/page.tsx
index 41685e7..1e26002 100644
--- a/src/app/changelog/[slug]/page.tsx
+++ b/src/app/changelog/[slug]/page.tsx
@@ -137,7 +137,7 @@ export default async function ChangelogEntryPage({
{/* Entry header */}
<article className="prose prose-gray max-w-none dark:prose-invert">
- <header className="not-prose mb-4 sm:mb-8">
+ <div className="not-prose mb-4 sm:mb-8">
<div className="mb-4 flex items-center gap-4 text-sm text-gray-600 dark:text-gray-400">
<DateTime dateTime={entry.metadata.date}>
{formattedDate}
@@ -153,7 +153,7 @@ export default async function ChangelogEntryPage({
<ChangelogVersionBadgeLink version={entry.metadata.version} />
</div>
) : null}
- </header>
+ </div>
{/* Author and social sharing */}
<div className="my-4 flex flex-col justify-between sm:my-8 sm:flex-row sm:items-center">
diff --git a/src/app/changelog/layout.tsx b/src/app/changelog/layout.tsx
index 68a0487..8a910c8 100644
--- a/src/app/changelog/layout.tsx
+++ b/src/app/changelog/layout.tsx
@@ -85,25 +85,7 @@ interface ChangelogLayoutProps {
export default function ChangelogLayout({ children }: ChangelogLayoutProps) {
return (
<>
- <Header
- locale={"en"}
- translations={{
- navLinks: {
- home: "Home",
- features: "Features",
- faq: "FAQ",
- github: "GitHub",
- githubCTA: "Star on GitHub",
- tagline: "Free & Open-Source Invoice Generator",
- },
- switchLanguageText: "Switch Language",
- goToAppText: "Open app",
- startInvoicingButtonText: "Start Invoicing",
- changelogLinkText: "Changelog",
- termsOfServiceLinkText: "Terms of Service",
- }}
- hideLanguageSwitcher={true}
- />
+ <Header />
{children}
<Footer />
</>
diff --git a/src/app/founder/layout.tsx b/src/app/founder/layout.tsx
index 758f948..ea98414 100644
--- a/src/app/founder/layout.tsx
+++ b/src/app/founder/layout.tsx
@@ -86,25 +86,7 @@ interface FounderLayoutProps {
export default function FounderLayout({ children }: FounderLayoutProps) {
return (
<>
- <Header
- locale={"en"}
- translations={{
- navLinks: {
- home: "Home",
- features: "Features",
- faq: "FAQ",
- github: "GitHub",
- githubCTA: "Star on GitHub",
- tagline: "Free & Open-Source Invoice Generator",
- },
- switchLanguageText: "Switch Language",
- goToAppText: "Open app",
- startInvoicingButtonText: "Start Invoicing",
- changelogLinkText: "Changelog",
- termsOfServiceLinkText: "Terms of Service",
- }}
- hideLanguageSwitcher={true}
- />
+ <Header />
{children}
<Footer />
</>
diff --git a/src/app/layout.tsx b/src/app/layout.tsx
index 9ef185f..55afe6a 100644
--- a/src/app/layout.tsx
+++ b/src/app/layout.tsx
@@ -1,7 +1,6 @@
import { DeviceContextProvider } from "@/contexts/device-context";
import { checkDeviceUserAgent } from "@/lib/check-device.server";
import { NextIntlClientProvider } from "next-intl";
-// import { ReactScan } from "@/components/dev/react-scan";
import { ResponsiveIndicator } from "@/components/dev/responsive-indicator";
import { SpeedInsights } from "@vercel/speed-insights/next";
@@ -85,8 +84,6 @@ export default async function RootLayout({
return (
<html lang="en">
- {/* Performance monitoring only in development */}
- {/* {process.env.NODE_ENV !== "development" ? null : <ReactScan />} */}
<body>
<DeviceContextProvider
isDesktop={isDesktopServer}
diff --git a/src/app/tos/layout.tsx b/src/app/tos/layout.tsx
index 63c9b08..8ce775c 100644
--- a/src/app/tos/layout.tsx
+++ b/src/app/tos/layout.tsx
@@ -79,25 +79,7 @@ interface TosLayoutProps {
export default function TosLayout({ children }: TosLayoutProps) {
return (
<>
- <Header
- locale={"en"}
- translations={{
- navLinks: {
- home: "Home",
- features: "Features",
- faq: "FAQ",
- github: "GitHub",
- githubCTA: "Star on GitHub",
- tagline: "Free & Open-Source Invoice Generator",
- },
- switchLanguageText: "Switch Language",
- goToAppText: "Open app",
- startInvoicingButtonText: "Start Invoicing",
- changelogLinkText: "Changelog",
- termsOfServiceLinkText: "Terms of Service",
- }}
- hideLanguageSwitcher={true}
- />
+ <Header />
{children}
<Footer />
</>
diff --git a/src/components/dev/react-scan.tsx b/src/components/dev/react-scan.tsx
deleted file mode 100644
index f061f7e..0000000
--- a/src/components/dev/react-scan.tsx
+++ /dev/null
@@ -1,27 +0,0 @@
-"use client";
-// react-scan must be imported before react
-import { scan } from "react-scan";
-import { useEffect, useRef } from "react";
-
-/**
- * React-scan is a tool for detecting and fixing issues with React
- * components https://github.com/aidenybai/react-scan#readme
- */
-export function ReactScan() {
- const hasInitialized = useRef(false);
-
- useEffect(() => {
- if (hasInitialized.current) return;
-
- try {
- scan({
- enabled: true,
- });
- hasInitialized.current = true;
- } catch (error) {
- console.error("Failed to initialize react-scan:", error);
- }
- }, []);
-
- return <></>;
-}
diff --git a/src/components/ui/faq-accordion.tsx b/src/components/ui/faq-accordion.tsx
new file mode 100644
index 0000000..5616038
--- /dev/null
+++ b/src/components/ui/faq-accordion.tsx
@@ -0,0 +1,51 @@
+import { PlusIcon } from "lucide-react";
+import * as React from "react";
+
+import { cn } from "@/lib/utils";
+
+interface FaqAccordionProps {
+ children: React.ReactNode;
+ className?: string;
+}
+
+function FaqAccordion({ children, className }: FaqAccordionProps) {
+ return <div className={cn("space-y-2", className)}>{children}</div>;
+}
+
+interface FaqAccordionItemProps {
+ question: React.ReactNode;
+ children: React.ReactNode;
+ className?: string;
+}
+
+function FaqAccordionItem({
+ question,
+ children,
+ className,
+}: FaqAccordionItemProps) {
+ return (
+ <details
+ className={cn(
+ "group cursor-pointer border-b border-dashed border-stone-300 transition-all duration-200 last:border-b-0",
+ className,
+ )}
+ >
+ <summary className="flex cursor-pointer select-none list-none appearance-none items-center justify-between gap-2 py-3 text-left [&::-webkit-details-marker]:hidden">
+ <h3 className="text-base font-medium text-stone-900">{question}</h3>
+ <PlusIcon
+ className="size-5 shrink-0 text-stone-400 transition-all duration-200 will-change-transform group-open:rotate-45 group-hover:text-stone-900"
+ aria-hidden="true"
+ />
+ </summary>
+ <div className="overflow-hidden">
+ <div className="pb-4 pr-4">
+ <p className="cursor-default text-pretty text-sm leading-relaxed text-stone-600">
+ {children}
+ </p>
+ </div>
+ </div>
+ </details>
+ );
+}
+
+export { FaqAccordion, FaqAccordionItem };