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

Fix pinned events banner reappearing when loading #3519

Merged
merged 2 commits into from
Sep 23, 2024

Conversation

jmartinesp
Copy link
Member

@jmartinesp jmartinesp commented Sep 23, 2024

Content

Change the RustTimeline.timelineItems property from a MutableStateFlow with an empty list to a MutableSharedFlow which will be populated with the contents of the Rust SDK timeline as soon as they're available.

Motivation and context

Fix an issue where the display animation happened twice when loading items because the first items loaded into the pinned events timeline were an incorrect empty list.

Tests

  • Open a room with pinned events.
  • The animation should run only once.

Tested devices

  • Physical
  • Emulator
  • OS version(s): 14

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

@jmartinesp jmartinesp added the PR-Bugfix For bug fix label Sep 23, 2024
@jmartinesp jmartinesp requested a review from a team as a code owner September 23, 2024 10:05
@jmartinesp jmartinesp requested review from bmarty and removed request for a team September 23, 2024 10:05
@jmartinesp jmartinesp force-pushed the fix/jme/pinned-events-banner-reappearing branch from 1fde1ca to d28d11a Compare September 23, 2024 10:10
Copy link
Contributor

github-actions bot commented Sep 23, 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/4KtJWi

Make the `RustTimelineItem.timelineItems` property a `SharedFlow` so we don't always incorrectly load an empty state by default.
@jmartinesp jmartinesp force-pushed the fix/jme/pinned-events-banner-reappearing branch from d28d11a to 749376c Compare September 23, 2024 11:07
Copy link

sonarcloud bot commented Sep 23, 2024

Copy link

codecov bot commented Sep 23, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 82.67%. Comparing base (5c7ac76) to head (28a5105).
Report is 9 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #3519   +/-   ##
========================================
  Coverage    82.67%   82.67%           
========================================
  Files         1731     1731           
  Lines        40863    40863           
  Branches      4971     4971           
========================================
  Hits         33785    33785           
  Misses        5315     5315           
  Partials      1763     1763           

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

@frebib
Copy link
Contributor

frebib commented Sep 23, 2024

Does this also solve the weirdness I see sometimes that causes the banner to slide in diagonally from the top-left instead of straight down?

@ganfra
Copy link
Member

ganfra commented Sep 23, 2024

Does this also solve the weirdness I see sometimes that causes the banner to slide in diagonally from the top-left instead of straight down?

Yes it does!

@ganfra ganfra added the Run-Maestro Starts a Maestro Cloud session to run integration tests label Sep 23, 2024
@github-actions github-actions bot removed the Run-Maestro Starts a Maestro Cloud session to run integration tests label Sep 23, 2024
@jmartinesp jmartinesp merged commit 16d5be3 into develop Sep 23, 2024
29 checks passed
@jmartinesp jmartinesp deleted the fix/jme/pinned-events-banner-reappearing branch September 23, 2024 13:19
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.

3 participants