summaryrefslogtreecommitdiff
path: root/src/lib/activitypub
diff options
context:
space:
mode:
authorRaphael <raphaelkabo@gmail.com>2024-02-05 09:18:41 +0000
committerRaphael Kabo <raphaelkabo@hey.com>2024-02-05 21:46:59 +0000
commitbe317850f203c428f77394f824908ecff500cf78 (patch)
tree4c16335c590ac01269e0adb3940a3bc21f121ead /src/lib/activitypub
parentecff04b132db687f67d9a6cda2d1c13831c45394 (diff)
Fix Pleroma federation, add hidden RSVP option
Diffstat (limited to 'src/lib/activitypub')
-rw-r--r--src/lib/activitypub/templates.ts14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lib/activitypub/templates.ts b/src/lib/activitypub/templates.ts
new file mode 100644
index 0000000..cab9ada
--- /dev/null
+++ b/src/lib/activitypub/templates.ts
@@ -0,0 +1,14 @@
+import { IEvent } from "../../models/Event.js";
+import getConfig from "../config.js";
+const config = getConfig();
+
+export const successfulRSVPResponse = ({
+ event,
+ newAttendee,
+ fullAttendee,
+}: {
+ event: IEvent;
+ newAttendee: { id: string; name: string };
+ fullAttendee: { _id: string };
+}) =>
+ `<span class="h-card"><a href="${newAttendee.id}" class="u-url mention">@<span>${newAttendee.name}</span></a></span> Thanks for RSVPing! You can remove yourself from the RSVP list by clicking <a href="https://${config.general.domain}/oneclickunattendevent/${event.id}/${fullAttendee._id}">here</a>.`;