revert(settings): restore the flat settings navigation

Revert the nine-group consolidation and the card relocations back to the
flat sidebar: sessions, trusted devices, and login activity return to
Privacy, and account deletion returns inline under Advanced. Drop the
/settings/layout redirect and the now-unused group and sign-in cross-link
i18n keys across all six locales.

Keep the collapse-by-default sessions and activity cards, the medical-history
cross-link from "About me", and the chronic-conditions consolidation.
This commit is contained in:
Marc-André Bombeck committed 2026-06-29 07:12:10 +02:00
1 parent 7bd26ff2bd
commit f564cdeef7
19 files changed
+518 -1133

No files matched your search

@@ -1,70 +0,0 @@
/**
* v1.25.1 (H1) — sign-in management consolidation.
*
* Active sessions, trusted devices, and the login-activity feed moved out of
* the Data & Privacy group into Account → Security so every "who can sign in as
* me" control sits in one place. This SSR test pins that the three cards render
* inside `<SecuritySection>`.
*/
import { describe, it, expect, vi } from "vitest";
import { renderToStaticMarkup } from "react-dom/server";
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
vi.mock("@/hooks/use-auth", () => ({
useAuth: () => ({ isAuthenticated: true, isLoading: false }),
}));
import { I18nProvider } from "@/lib/i18n/context";
import { queryKeys } from "@/lib/query-keys";
import { SecuritySection } from "../index";
function render() {
const client = new QueryClient({
defaultOptions: {
queries: {
retry: false,
staleTime: Number.POSITIVE_INFINITY,
refetchOnMount: false,
},
},
});
// Seed the MFA status so the second-factor cards paint instead of skeletons.
client.setQueryData(queryKeys.mfaStatus(), {
totp: { enabled: false },
recoveryCodesRemaining: 0,
webauthn: [],
passkeyNudgeDismissed: true,
});
client.setQueryData(queryKeys.passkeys(), []);
// Seed the embedded sign-in reads so the cards paint without firing network.
client.setQueryData(queryKeys.sessions(), { sessions: [] });
client.setQueryData(queryKeys.securityActivity(), { events: [] });
client.setQueryData(queryKeys.trustedDevices(), {
devices: [
{
id: "td-1",
label: "Firefox on macOS",
isCurrent: true,
createdAt: "2099-01-01T00:00:00.000Z",
lastUsedAt: "2099-01-01T00:00:00.000Z",
expiresAt: "2099-01-01T00:00:00.000Z",
},
],
});
return renderToStaticMarkup(
<I18nProvider initialLocale="en">
<QueryClientProvider client={client}>
<SecuritySection />
</QueryClientProvider>
</I18nProvider>,
);
}
describe("<SecuritySection> — sign-in management home (H1)", () => {
it("renders the active-session, trusted-device, and security-activity cards", () => {
const html = render();
expect(html).toContain('data-slot="settings-security-sessions-card"');
expect(html).toContain('data-slot="settings-trusted-devices-card"');
expect(html).toContain('data-slot="settings-security-activity-card"');
});
});