v3: added comment likes, added votes/likes list view, added db migrations mechanism, updated project dependencies
All checks were successful
Build and Publish Docker Image / build-and-push (push) Successful in 42s

This commit is contained in:
khannurien
2026-06-21 14:17:56 +00:00
parent 888aae45cf
commit 7afb5d3f07
25 changed files with 1475 additions and 840 deletions

View File

@@ -162,6 +162,7 @@ export interface Comment {
createdAt: Date;
updatedAt?: Date;
deleted: boolean;
likeCount: number;
authorUsername: string;
authorAvatarMime?: string;
}
@@ -249,7 +250,8 @@ export type NotificationType =
| "playlist_dump_added"
| "dump_upvoted"
| "user_mentioned"
| "dump_commented";
| "dump_commented"
| "comment_liked";
export interface PlaylistFollowedData {
followerId: string;
@@ -301,6 +303,14 @@ export interface DumpCommentedData {
dumpTitle: string;
}
export interface CommentLikedData {
likerId: string;
likerUsername: string;
commentId: string;
dumpId: string;
dumpTitle: string;
}
export type NotificationData =
| PlaylistFollowedData
| UserFollowedData
@@ -308,7 +318,8 @@ export type NotificationData =
| PlaylistDumpAddedData
| DumpUpvotedData
| UserMentionedData
| DumpCommentedData;
| DumpCommentedData
| CommentLikedData;
export interface Notification {
id: string;
@@ -350,6 +361,7 @@ export interface WSWelcomeMessage {
type: "welcome";
users: OnlineUser[];
myVotes: string[];
myCommentLikes: string[];
unreadNotificationCount: number;
}
export interface WSPresenceUpdateMessage {
@@ -369,6 +381,19 @@ export interface WSVoteAckMessage {
action: "cast" | "remove";
voteCount: number;
}
export interface WSCommentLikesUpdateMessage {
type: "comment_likes_update";
commentId: string;
likeCount: number;
likerId: string;
action: "cast" | "remove";
}
export interface WSCommentLikeAckMessage {
type: "comment_like_ack";
commentId: string;
action: "cast" | "remove";
likeCount: number;
}
export interface WSDumpCreatedMessage {
type: "dump_created";
dump: RawDump;
@@ -435,6 +460,8 @@ export type IncomingWSMessage =
| WSPresenceUpdateMessage
| WSVotesUpdateMessage
| WSVoteAckMessage
| WSCommentLikesUpdateMessage
| WSCommentLikeAckMessage
| WSDumpCreatedMessage
| WSDumpUpdatedMessage
| WSDumpDeletedMessage
@@ -465,11 +492,21 @@ export interface WSVoteRemoveMessage {
type: "vote_remove";
dumpId: string;
}
export interface WSCommentLikeCastMessage {
type: "comment_like_cast";
commentId: string;
}
export interface WSCommentLikeRemoveMessage {
type: "comment_like_remove";
commentId: string;
}
export type OutgoingWSMessage =
| WSPongMessage
| WSVoteCastMessage
| WSVoteRemoveMessage;
| WSVoteRemoveMessage
| WSCommentLikeCastMessage
| WSCommentLikeRemoveMessage;
/**
* Follows