From cf47929d5bc785c2cf4b03624f60e14a2bb73c0a Mon Sep 17 00:00:00 2001 From: Joscha Eckert <34318751+josxha@users.noreply.github.com> Date: Sun, 9 Nov 2025 00:41:19 +0100 Subject: [PATCH 1/6] fix github release link --- martin/martin-ui/src/components/header.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/martin/martin-ui/src/components/header.tsx b/martin/martin-ui/src/components/header.tsx index 85fe94833..34e7e353d 100644 --- a/martin/martin-ui/src/components/header.tsx +++ b/martin/martin-ui/src/components/header.tsx @@ -21,8 +21,8 @@ export function Header() { {import.meta.env.VITE_MARTIN_VERSION ? ( {import.meta.env.VITE_MARTIN_VERSION} From ef29e43cc1574ded6ae4be448be61002846feabf Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 8 Nov 2025 23:45:21 +0000 Subject: [PATCH 2/6] chore(fmt): apply pre-commit formatting fixes --- martin/martin-ui/src/components/header.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/martin/martin-ui/src/components/header.tsx b/martin/martin-ui/src/components/header.tsx index 34e7e353d..07bba256d 100644 --- a/martin/martin-ui/src/components/header.tsx +++ b/martin/martin-ui/src/components/header.tsx @@ -21,8 +21,9 @@ export function Header() { {import.meta.env.VITE_MARTIN_VERSION ? ( {import.meta.env.VITE_MARTIN_VERSION} From e4df3926bbcc7b7a4c1a7871a333631ddd93a924 Mon Sep 17 00:00:00 2001 From: Joscha Eckert <34318751+josxha@users.noreply.github.com> Date: Sun, 9 Nov 2025 00:56:21 +0100 Subject: [PATCH 3/6] add `noopener noreferrer`, fix test --- .../__tests__/components/__snapshots__/header.test.tsx.snap | 3 ++- martin/martin-ui/src/components/header.tsx | 2 +- martin/martin-ui/vitest.setup.ts | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap b/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap index 732104062..894e36f5f 100644 --- a/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap +++ b/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap @@ -1255,7 +1255,8 @@ exports[`Header Component > renders correctly 1`] = ` diff --git a/martin/martin-ui/src/components/header.tsx b/martin/martin-ui/src/components/header.tsx index 07bba256d..2ee54ddac 100644 --- a/martin/martin-ui/src/components/header.tsx +++ b/martin/martin-ui/src/components/header.tsx @@ -23,7 +23,7 @@ export function Header() { {import.meta.env.VITE_MARTIN_VERSION} diff --git a/martin/martin-ui/vitest.setup.ts b/martin/martin-ui/vitest.setup.ts index 5ff727643..3a6da0972 100644 --- a/martin/martin-ui/vitest.setup.ts +++ b/martin/martin-ui/vitest.setup.ts @@ -21,7 +21,7 @@ vi.mock('react', async () => { }); // Mock import.meta.env globally - Vitest handles this natively, but we set defaults -vi.stubEnv('VITE_MARTIN_VERSION', 'v0.0.0-test'); +vi.stubEnv('VITE_MARTIN_VERSION', '0.0.0-test'); vi.stubEnv('VITE_MARTIN_BASE', 'http://localhost:3000'); // Suppress console errors during tests From 878bc8673c404577012b7b00a0cb87db1102e4cc Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sat, 8 Nov 2025 23:56:40 +0000 Subject: [PATCH 4/6] chore(fmt): apply pre-commit formatting fixes --- martin/martin-ui/src/components/header.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/martin/martin-ui/src/components/header.tsx b/martin/martin-ui/src/components/header.tsx index 2ee54ddac..19bc744a6 100644 --- a/martin/martin-ui/src/components/header.tsx +++ b/martin/martin-ui/src/components/header.tsx @@ -23,7 +23,8 @@ export function Header() { {import.meta.env.VITE_MARTIN_VERSION} From a4fa394304a61383f350655e22965120594c8462 Mon Sep 17 00:00:00 2001 From: Joscha Eckert <34318751+josxha@users.noreply.github.com> Date: Sun, 9 Nov 2025 01:05:19 +0100 Subject: [PATCH 5/6] use same martin version format in all tests --- .../__tests__/components/__snapshots__/header.test.tsx.snap | 5 +++-- martin/martin-ui/__tests__/components/header.test.tsx | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap b/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap index 894e36f5f..beabf6573 100644 --- a/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap +++ b/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap @@ -1256,9 +1256,10 @@ exports[`Header Component > renders correctly 1`] = ` class="items-center justify-center rounded-md border px-2 py-0.5 text-xs font-medium w-fit whitespace-nowrap shrink-0 [&>svg]:size-3 gap-1 [&>svg]:pointer-events-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive transition-[color,box-shadow] overflow-hidden border-transparent bg-primary text-primary-foreground [a&]:hover:bg-primary/90 hover:bg-purple-700 hidden md:block p-1" data-slot="badge" href="https://github.com/maplibre/martin/releases/tag/martin-v0.0.0-test" - target="_blank" rel="noopener noreferrer" + rel="noopener noreferrer" + target="_blank" > - v0.0.0-test + 0.0.0-test
{ it('displays the Martin version', () => { const { getByText } = render(
); - expect(getByText('v0.0.0-test')).toBeTruthy(); + expect(getByText('0.0.0-test')).toBeTruthy(); }); it('contains navigation links', () => { From ab0ecdd77e4f98d28be07605194a7615b791380f Mon Sep 17 00:00:00 2001 From: Frank Elsinga Date: Sun, 9 Nov 2025 16:53:31 +0100 Subject: [PATCH 6/6] Apply suggestions from code review --- .../__tests__/components/__snapshots__/header.test.tsx.snap | 4 ++-- martin/martin-ui/__tests__/components/header.test.tsx | 4 ++-- martin/martin-ui/vitest.setup.ts | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap b/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap index beabf6573..08008c499 100644 --- a/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap +++ b/martin/martin-ui/__tests__/components/__snapshots__/header.test.tsx.snap @@ -1255,11 +1255,11 @@ exports[`Header Component > renders correctly 1`] = `
{ it('displays the Martin version', () => { const { getByText } = render(
); - expect(getByText('0.0.0-test')).toBeTruthy(); + expect(getByText('1.0.0')).toBeTruthy(); }); it('contains navigation links', () => { diff --git a/martin/martin-ui/vitest.setup.ts b/martin/martin-ui/vitest.setup.ts index 3a6da0972..c2b96a32c 100644 --- a/martin/martin-ui/vitest.setup.ts +++ b/martin/martin-ui/vitest.setup.ts @@ -21,7 +21,7 @@ vi.mock('react', async () => { }); // Mock import.meta.env globally - Vitest handles this natively, but we set defaults -vi.stubEnv('VITE_MARTIN_VERSION', '0.0.0-test'); +vi.stubEnv('VITE_MARTIN_VERSION', '1.0.0'); vi.stubEnv('VITE_MARTIN_BASE', 'http://localhost:3000'); // Suppress console errors during tests