Fix logo not loading under a non-root base path

The logo <img> used a hardcoded absolute "/logo.png" path, which only resolves correctly when the app is served from the domain root. Under the GitHub Pages demo (served from /webspeak3/), this 404'd. Vite already rewrites asset references in index.html for the configured base path, but plain string literals in JSX aren't touched, so this needs import.meta.env.BASE_URL explicitly.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
MoepchiandClaude Sonnet 5 committed 2026-08-01 00:23:56 +02:00
1 parent fe1b5ff991
commit 65813b6367
1 file changed
+1 -1
+1 -1
View File
@@ -2391,7 +2391,7 @@ function AppInner() {
>
{theme === "dark" ? "☀️" : "🌙"}
</button>
<img src="/logo.png" alt="" className="ts-app-logo" />
<img src={`${import.meta.env.BASE_URL}logo.png`} alt="" className="ts-app-logo" />
<span className="ts-app-title">WebSpeak3</span>
</div>