Add docker publish flow, node blocklist & API updates
Replace docker/metadata GH Action with a docker-publish.sh driven workflow (supports auto-versioning, extra tags, multi-arch builds and optional builder). Update docs and READMEs to use the updater and new publish flow. Add server-side swarm/node blocklist support and admin nodes API. Improve auth endpoints (me, logout, switch, session accounts) and support account switching. Extend bots API to support custom LLM provider and optional endpoint. Enforce node blocklist on chat send/receive, refactor link preview handling into dedicated preview modules, and enhance notifications and posts like/repost handlers to accept both signed actions and regular auth flows. Misc: remove admin update UI details, add helper libs (media previews, node-blocklist, reposts, notifications, etc.), and minor housekeeping (pyc, workflow tweaks).
This commit is contained in:
@@ -13,6 +13,14 @@ interface NotificationActor {
|
||||
avatarUrl: string | null;
|
||||
}
|
||||
|
||||
interface NotificationTarget {
|
||||
handle: string;
|
||||
displayName: string | null;
|
||||
avatarUrl: string | null;
|
||||
nodeDomain?: string | null;
|
||||
isBot?: boolean | null;
|
||||
}
|
||||
|
||||
interface NotificationPost {
|
||||
id: string;
|
||||
content: string;
|
||||
@@ -24,6 +32,7 @@ interface Notification {
|
||||
createdAt: string;
|
||||
readAt: string | null;
|
||||
actor: NotificationActor | null;
|
||||
target: NotificationTarget | null;
|
||||
post: NotificationPost | null;
|
||||
}
|
||||
|
||||
@@ -77,17 +86,28 @@ export default function NotificationsPage() {
|
||||
};
|
||||
|
||||
const getNotificationText = (notification: Notification) => {
|
||||
const targetName = notification.target?.displayName || notification.target?.handle;
|
||||
switch (notification.type) {
|
||||
case 'follow':
|
||||
return 'followed you';
|
||||
return notification.target?.isBot && targetName
|
||||
? `followed your bot ${targetName}`
|
||||
: 'followed you';
|
||||
case 'like':
|
||||
return 'liked your post';
|
||||
return notification.target?.isBot && targetName
|
||||
? `liked a post from ${targetName}`
|
||||
: 'liked your post';
|
||||
case 'repost':
|
||||
return 'reposted your post';
|
||||
return notification.target?.isBot && targetName
|
||||
? `reposted a post from ${targetName}`
|
||||
: 'reposted your post';
|
||||
case 'mention':
|
||||
return 'mentioned you';
|
||||
return notification.target?.isBot && targetName
|
||||
? `mentioned your bot ${targetName}`
|
||||
: 'mentioned you';
|
||||
case 'reply':
|
||||
return 'replied to your post';
|
||||
return notification.target?.isBot && targetName
|
||||
? `replied to a post from ${targetName}`
|
||||
: 'replied to your post';
|
||||
default:
|
||||
return 'interacted with you';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user