Say what somebody did, not that they did something

The activity view told an owner that a delegate acted on their record. With
delegated writing it can say which act: added a reading, recorded a lab result,
marked a dose. The mapping already existed as a pure module with its own test
and a fallback for anything unmapped; this is the wire it was missing.
This commit is contained in:
Marc-André Bombeck committed 2026-08-03 12:24:05 +02:00
1 parent 59965e141e
commit 748def03bd
1 file changed
+2 -1
@@ -7,6 +7,7 @@ import { SettingsCardHeader } from "@/components/settings/_card-header";
import { EmptyState } from "@/components/ui/empty-state";
import { QueryErrorCard } from "@/components/ui/query-error-card";
import { useFormatters, useTranslations } from "@/lib/i18n/context";
import { recordActivityVerbLine } from "@/lib/record-activity/activity-verb";
import { accountLabel } from "@/lib/sharing/account-access-view";
import {
useRecordActivity,
@@ -113,7 +114,7 @@ function ActivityRow({ entry }: { entry: RecordActivityEntry }) {
>
<span className="text-foreground text-sm">
{entry.accesses === null
? t("recordSharing.activity.acted", { name: who })
? recordActivityVerbLine(t, entry.action, who)
: t("recordSharing.activity.opened", {
name: who,
count: entry.accesses,