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

Draft : also clear draft when composer is blank #3115

Merged
merged 1 commit into from
Jul 1, 2024

Conversation

ganfra
Copy link
Member

@ganfra ganfra commented Jul 1, 2024

Type of change

  • Feature
  • Bugfix
  • Technical
  • Other :

Content

At the moment, draft was cleared only when getting the draft, which is not enought.
If the app is put in bakground while you have a text in the composer, then the draft will be saved.
If you then send the message, and then close the room, the draft will remain and will reappear when re-opening the room.

So, this will now take care to clear the draft when composer is blank too.

Motivation and context

Screenshots / GIFs

Tests

  • Step 1
  • Step 2
  • Step ...

Tested devices

  • Physical
  • Emulator
  • OS version(s):

Checklist

  • Changes have been tested on an Android device or Android emulator with API 23
  • UI change has been tested on both light and dark themes
  • Accessibility has been taken into account. See https://github.com/element-hq/element-x-android/blob/develop/CONTRIBUTING.md#accessibility
  • Pull request is based on the develop branch
  • Pull request title will be used in the release note, it clearly define what will change for the user
  • Pull request includes screenshots or videos if containing UI changes
  • Pull request includes a sign off
  • You've made a self review of your PR

@ganfra ganfra marked this pull request as ready for review July 1, 2024 10:06
@ganfra ganfra requested a review from a team as a code owner July 1, 2024 10:06
@ganfra ganfra requested review from jmartinesp and bmarty and removed request for a team and jmartinesp July 1, 2024 10:06
@ganfra ganfra added the PR-Bugfix For bug fix label Jul 1, 2024
Copy link
Contributor

github-actions bot commented Jul 1, 2024

📱 Scan the QR code below to install the build (arm64 only) for this PR.
QR code
If you can't scan the QR code you can install the build via this link: https://i.diawi.com/RrJxxP

@ganfra ganfra force-pushed the feature/fga/fix_draft_not_cleared branch from b82f35d to 3a610e6 Compare July 1, 2024 10:24
Copy link

codecov bot commented Jul 1, 2024

Codecov Report

Attention: Patch coverage is 30.00000% with 7 lines in your changes missing coverage. Please review.

Project coverage is 75.95%. Comparing base (aa0a6ce) to head (3a610e6).
Report is 6 commits behind head on develop.

Files Patch % Lines
...messages/impl/draft/DefaultComposerDraftService.kt 0.00% 6 Missing ⚠️
...s/impl/messagecomposer/MessageComposerPresenter.kt 75.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #3115      +/-   ##
===========================================
- Coverage    75.95%   75.95%   -0.01%     
===========================================
  Files         1636     1636              
  Lines        38608    38612       +4     
  Branches      7462     7463       +1     
===========================================
+ Hits         29326    29327       +1     
- Misses        5393     5396       +3     
  Partials      3889     3889              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@bmarty bmarty left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@ganfra ganfra added the Run-Maestro Starts a Maestro Cloud session to run integration tests label Jul 1, 2024
@ganfra ganfra enabled auto-merge July 1, 2024 10:45
@github-actions github-actions bot removed the Run-Maestro Starts a Maestro Cloud session to run integration tests label Jul 1, 2024
Copy link

sonarcloud bot commented Jul 1, 2024

@ganfra ganfra merged commit 32b1b6e into develop Jul 1, 2024
25 of 27 checks passed
@ganfra ganfra deleted the feature/fga/fix_draft_not_cleared branch July 1, 2024 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR-Bugfix For bug fix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants