Skip to content

Edit-message (7/n): Implement edit-message methods on MessageStore #1484

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

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

Conversation

chrisbobbe
Copy link
Collaborator

This PR, toward the edit-message feature #126, implements three new methods on MessageStore:

editMessage, to be called when the user taps the "Edit message" button in the message action sheet:

getEditMessageErrorStatus, to be called when rendering the message list; showing a loading state when we haven't gotten the update-message event yet, and an error state for a failed edit request:

image image

(The UI text isn't final; see updates on CZO: #mobile-design > edit message @ 💬)

takeFailedMessageEdit, to be called when you tap the error message pictured above, so we can put you back in the edit box, starting with the text you'd tried to edit to. This part is from CZO discussion: #mobile-design > edit message @ 💬

Related: #126

@chrisbobbe chrisbobbe added the maintainer review PR ready for review by Zulip maintainers label Apr 24, 2025
@chrisbobbe chrisbobbe requested a review from PIG208 April 24, 2025 03:12
@chrisbobbe
Copy link
Collaborator Author

chrisbobbe commented Apr 24, 2025

Marking as a draft because I still have a TODO for some tests about delete-message events. Done; ready for review!

@chrisbobbe chrisbobbe changed the title Edit-message (6/n): Implement edit-message methods on MessageStore Edit-message (7/n): Implement edit-message methods on MessageStore Apr 24, 2025
@chrisbobbe chrisbobbe marked this pull request as ready for review April 25, 2025 21:29
@chrisbobbe
Copy link
Collaborator Author

Revision pushed, this time putting the tests in test/model/message_test.dart instead of test/model/store_test.dart (but still testing against the whole PerAccountStore API, not the MessageStoreImpl substore, following the reasoning in ec9aa35).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintainer review PR ready for review by Zulip maintainers
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants