SrigadaAkshayKumar/chatapp-frontend

Add Message Deletion Feature (Both Sides)

开放

#7 创建于 2025年2月9日

 (0 条评论) (0 个反应) (0 位负责人)JavaScript (3 个派生)auto 404
Backendenhancementhelp wanted

仓库指标

星标
 (1 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

🛑 Add Message Deletion Feature (Both Sides)

📌 Description

Currently, users can only delete messages from their own view, but the recipient still sees them. This feature will allow users to delete messages for both sender and recipient, enhancing privacy and control over conversations.

🚀 Feature Requirements

  • ✅ Add a "Delete for Me" option (removes message only for the user).
  • ✅ Add a "Delete for Everyone" option (removes message from both sender and recipient's chat).
  • ✅ Ensure a confirmation dialog before deletion.
  • ✅ Replace deleted messages with a placeholder like "This message was deleted."
  • ✅ Set a time limit (e.g., messages can only be deleted within X minutes after sending).

🛠 Tech Stack

  • Frontend: JavaScript / React
  • Backend: Firebase / Node.js

🔄 Possible Implementation Steps

  1. Update the message database schema to support soft deletion.
  2. Implement delete options in the chat UI.
  3. Ensure real-time updates so deleted messages disappear instantly.
  4. Test for edge cases, such as deleting a message while the recipient is online.

🏷 Labels

🔹 enhancement
🔹 help wanted

贡献者指南