No status report linked.
+ );
+ }
+
+ async function createReport() {
+ const promise = (async () => {
+ const created = await create.mutateAsync({
+ title,
+ status: "investigating",
+ pageId: Number(pageId),
+ pageComponents: [],
+ date: new Date(),
+ message,
+ notifySubscribers,
+ incidentId: incident.id,
+ });
+ if (created && notifySubscribers) {
+ await notify.mutateAsync({ id: created.id });
+ }
+ })();
+ toast.promise(promise, {
+ loading: "Creating status report...",
+ success: "Status report created",
+ error: toastError,
+ });
+ await promise;
+ setMode(null);
+ }
+
+ const openReports = (reports ?? []).filter((r) => r.status !== "resolved");
+
+ return (
+
+
+ No status report yet. Your users only see what you publish there.
+
+
+
+
+
+ {mode === "link" ? (
+
+
+
+
+ ) : null}
+ {mode === "create" ? (
+
+
+
setTitle(e.target.value)} />
+
+ ) : null}
+
+ );
+}
diff --git a/apps/dashboard/src/components/incidents/incident-timeline.tsx b/apps/dashboard/src/components/incidents/incident-timeline.tsx
new file mode 100644
index 00000000..d25cb86b
--- /dev/null
+++ b/apps/dashboard/src/components/incidents/incident-timeline.tsx
@@ -0,0 +1,61 @@
+"use client";
+
+import type { RouterOutputs } from "@openstatus/api";
+import type { IncidentEventType } from "@openstatus/db/src/schema/incidents/constants";
+import { formatDistanceToNow } from "date-fns";
+
+import { ProcessMessage } from "@/components/content/process-message";
+import { personName } from "@/data/managed-incidents.client";
+
+type Event = NonNullable