mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-18 08:02:12 +00:00
Collapse the duplicated settings navigation so each surface lives in
one place:
- Appearance ("Darstellung") stops being a link hub and renders the
dashboard, insights, and every tracking module's settings inline as
stacked, anchored sections. Each module section keeps its module
gate, so a disabled module's section does not render. The standalone
Medikamente / Stimmung / Labor / Krankheit / Vorsorge nav entries are
gone; their routes 301-redirect to /settings/layout#<anchor>.
- Move the delivery channels out of Notifications into Integrations,
where the other connected services live. Notifications keeps only the
reminder types. /settings/channels now redirects to
/settings/integrations#channels; the per-channel anchors still resolve.
- Fold the clinician share-link surface into the health-record section
as a labelled Sharing group. /settings/sharing redirects to
/settings/gesundheitsakte#sharing.
- Drop the duplicated active-sessions and security-activity cards from
Account; they remain under Data & Privacy.
- Reserve the scrollbar gutter on the settings content column so a
section with a vertical scrollbar and one without render at the same
width.
Move-only: every card renders through its existing component unchanged.
55 lines
2.2 KiB
TypeScript
55 lines
2.2 KiB
TypeScript
"use client";
|
|
|
|
/**
|
|
* v1.18.0 (S5) — Settings → Gesundheitsakte (health record).
|
|
*
|
|
* The full health-record export is a distinct concept — a complete,
|
|
* clinician-ready record (PDF + FHIR R4 + a combined zip package) — and earns
|
|
* its own top-level settings home rather than sharing the page with the
|
|
* generic CSV / JSON data-out paths.
|
|
*
|
|
* The `doctorReport` module governs the data layer, not the Settings
|
|
* entry-point: as of v1.18.6.1 the nav entry always shows (the health record
|
|
* is a flagship export capability and should never silently vanish from
|
|
* Settings). The server-side `/api/export/health-record` route is the hard
|
|
* enforcement — it refuses with a 403 `module.disabled` envelope when the
|
|
* account has opted out, so a disabled doctor-report surface cannot be
|
|
* reached over a Bearer token either.
|
|
*
|
|
* v1.25.7 — the clinician share-link surface (formerly the standalone
|
|
* "Freigabe" section) folds in here as a labelled "Sharing" group below the
|
|
* export panel: a time-boxed read-only link is a sharing face of the SAME
|
|
* health record. `/settings/sharing` 301-redirects to
|
|
* `/settings/gesundheitsakte#sharing`. The backing model, the
|
|
* `/api/share-links` routes, and the public `/c/[token]` view are unchanged.
|
|
*/
|
|
|
|
import { useTranslations } from "@/lib/i18n/context";
|
|
import { HealthRecordExportPanel } from "@/components/settings/health-record-export-panel";
|
|
import { SharingSection } from "@/components/settings/sharing-section";
|
|
|
|
export function GesundheitsakteSection() {
|
|
const { t } = useTranslations();
|
|
|
|
// v1.18.6 (W9) — the visible page heading + subtitle come from the shared
|
|
// `<SettingsSectionFrame>` in the route; the export panel is the primary
|
|
// surface, with the share-links group sequenced below it.
|
|
return (
|
|
<div className="space-y-10">
|
|
<HealthRecordExportPanel />
|
|
|
|
<section id="sharing" className="scroll-mt-28 space-y-4">
|
|
<div className="space-y-0.5">
|
|
<h2 className="text-foreground text-lg font-semibold">
|
|
{t("settings.sections.sharing.title")}
|
|
</h2>
|
|
<p className="text-muted-foreground text-sm">
|
|
{t("settings.sections.sharing.subtitle")}
|
|
</p>
|
|
</div>
|
|
<SharingSection />
|
|
</section>
|
|
</div>
|
|
);
|
|
}
|