[web] emit mention notifications (#35611)

GitOrigin-RevId: 4852c217a8bf7f1fe71696604acbb0f7434d3f2a
This commit is contained in:
Kristina
2026-09-17 11:36:42 +00:00
committed by Copybot
parent 4e2840e247
commit 6f8a1be171
2 changed files with 21 additions and 0 deletions
@@ -85,6 +85,25 @@ class MockChatApi extends AbstractMockApi {
)
}
)
this.app.post(
'/project/:project_id/thread/:thread_id/messages/:message_id/edit',
(req, res) => {
const {
project_id: projectId,
thread_id: threadId,
message_id: messageId,
} = req.params
const { content, userId } = req.body
const thread = this.getThread(projectId, threadId)
const message = thread.find(msg => msg.id === messageId)
if (!message || (userId && message.user_id !== userId)) {
return res.sendStatus(404)
}
message.content = content
message.edited_at = Date.now()
res.sendStatus(204)
}
)
this.app.delete('/project/:project_id', (req, res) => {
const projectId = req.params.project_id
this.destroyProject(projectId)
+2
View File
@@ -21,6 +21,7 @@ export type CommentAddedEvent = {
userId: string
threadId: string
messageId: string
content: string
}
export type CommentResolvedEvent = {
@@ -40,6 +41,7 @@ export type CommentEditedEvent = {
userId: string
threadId: string
messageId: string
content: string
}
export type CommentDeletedEvent = {