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

Add an empty state to the room list #2342

Merged
merged 6 commits into from
Feb 2, 2024

Conversation

jmartinesp
Copy link
Contributor

Type of change

  • Feature
  • Bugfix
  • Technical
  • Other :

Content

  • Make RoomListDataSource.allRooms a SharedFlow so we can know when we don't have a value yet.
  • Map its output in RoomListPresenter to AsyncData.
  • Display the new empty state when the room list has loaded and has no items.
  • Use contentPadding for the room list bottom padding instead of an extra item.
  • Make the room list use a key for recycling components. This may cause crashes, but at least we'll know something is wrong with the room list.

Motivation and context

Closes #2330.

Screenshots / GIFs

Light Dark

Tests

  • Log into the app with a freshly created account, or leave all rooms in your current one.
  • The empty state view should appear, the 'start chat' button should work.
  • Join a room.
  • The empty state view should be gone.

Tested devices

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

Checklist

jmartinesp and others added 6 commits February 2, 2024 12:39
- Make `RoomListDataSource.allRooms` a `SharedFlow` so we can know when we don't have a value yet.
- Map its output in `RoomListPresenter` to `AsyncData`.
- Display the new empty state when the room list has loaded and has no items.
…RoomSummaryFactory.createFakeList` functions static ones
- Instead of an extra item, use `contentPadding`.
- Make sure each item has an unique id.
@jmartinesp jmartinesp requested a review from a team as a code owner February 2, 2024 12:35
@jmartinesp jmartinesp requested review from bmarty and removed request for a team February 2, 2024 12:35
Copy link

sonarcloud bot commented Feb 2, 2024

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

Copy link
Contributor

github-actions bot commented Feb 2, 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/X9A8BW

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. I have one question, that I have also asked on Figma.
Not blocking the PR.

Copy link
Member

Choose a reason for hiding this comment

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

I would remove the FAB in the case of an empty list, here the added button has the same effect.

Copy link
Contributor Author

@jmartinesp jmartinesp Feb 2, 2024

Choose a reason for hiding this comment

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

I made the same exact suggestion to @amshakal 😅 . She said it was to also make the meaning of the FAB easier for the user to understand or something along those lines. I'm ok with either leaving it or removing it, it shouldn't be much work.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

But yes, it's probably something we can handle in some other PR.

@jmartinesp jmartinesp added the Run-Maestro Starts a Maestro Cloud session to run integration tests label Feb 2, 2024
@github-actions github-actions bot removed the Run-Maestro Starts a Maestro Cloud session to run integration tests label Feb 2, 2024
@jmartinesp jmartinesp merged commit aabca49 into develop Feb 2, 2024
17 checks passed
@jmartinesp jmartinesp deleted the feature/jme/2330-add-empty-state-for-room-list branch February 2, 2024 15:30
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.

[Task] Add empty state for room list
3 participants