Add legal pages, ToS acceptance, and alpha banner
- Journal: Impressum (§5 TMG), Terms of Service, GDPR privacy page - Registration flow: required ToS checkbox, termsAcceptedAt persisted - Alpha banner on Journal (always visible); alpha badge on Planner hero - Footer with legal links + GitHub on both apps - Reduce PII: sendDefaultPii=false, Sentry init only after login (Journal) - Drop Sentry from Planner (no login, no consent possible) - Drop localStorage caching from i18n client detection - Sync SSR i18n resources each request so locale edits HMR without restart Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
6c1cd23358
commit
cc0f44258a
24 changed files with 773 additions and 206 deletions
|
|
@ -7,6 +7,9 @@ import { useTranslation } from "react-i18next";
|
|||
import { detectLocale } from "@trails-cool/i18n";
|
||||
import { getSessionUser } from "~/lib/auth.server";
|
||||
import { LocaleProvider } from "~/components/LocaleContext";
|
||||
import { AlphaBanner } from "~/components/AlphaBanner";
|
||||
import { Footer } from "~/components/Footer";
|
||||
import { initSentryClient } from "~/lib/sentry.client";
|
||||
import stylesheet from "@trails-cool/ui/styles.css?url";
|
||||
|
||||
export const links: LinksFunction = () => [{ rel: "stylesheet", href: stylesheet }];
|
||||
|
|
@ -116,7 +119,8 @@ export default function App({ loaderData }: Route.ComponentProps) {
|
|||
const locale = loaderData?.locale ?? "en";
|
||||
useEffect(() => {
|
||||
if (user) {
|
||||
Sentry.setUser({ id: user.id, username: user.username });
|
||||
initSentryClient();
|
||||
Sentry.setUser({ id: user.id });
|
||||
} else {
|
||||
Sentry.setUser(null);
|
||||
}
|
||||
|
|
@ -124,8 +128,10 @@ export default function App({ loaderData }: Route.ComponentProps) {
|
|||
|
||||
return (
|
||||
<LocaleProvider locale={locale}>
|
||||
<AlphaBanner />
|
||||
<NavBar user={user ?? null} />
|
||||
<Outlet />
|
||||
<Footer />
|
||||
</LocaleProvider>
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue