Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Generated By Dashwave AI] Align Message Content Deletion Experience with Web App #40

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

dashwave[bot]
Copy link

@dashwave dashwave bot commented Nov 29, 2024

This PR aligns the message content deletion experience with the web app. Key changes include:

  1. ComposeBox.js: Added an if condition to check if the compose box is in 'isEditing' mode. If not, a 'message-empty' error is added as a validation error. If in 'isEditing', the error is not added, allowing users to edit messages with empty content.

  2. ChatScreen.js: Removed the condition checking for empty content (content == "") to allow empty content to be accepted as input when editing messages.

  3. index.js: Commented out the buttons.push(deleteMessage) for conditions where message.isOutbox === true and message.sender_id === ownUser.user_id && messageNotDeleted(message) to refine actionsheets. Added a condition (ownUser.role === 200 && messageNotDeleted(message)) to allow admins to delete messages, using 'ownUser.role' instead of 'ownUser.isAdmin' as the latter is not readable.

These changes ensure a consistent and intuitive message editing and deletion experience across platforms, particularly for admin roles.

Copy link
Author

dashwave bot commented Nov 29, 2024

Build Status ❌ Failed
Build Time -
📱 Emulation Link -
Logs See Logs
Open in Workspace Dashwave Workspace

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants