Commit graph

254 commits

Author SHA1 Message Date
Benoit Marty
b104dba845 Remove Modifier parameter in private function when only default value is used.
This will improve the code coverage metrics, and this also fixes a few potential bug, where the Modifier was used several times.
2024-02-08 11:06:06 +01:00
Jorge Martin Espinosa
d06e5c23cb
Move migration screen to within the room list (#2361)
* Rename migration bg drawable and add night variant
* Move `migration` package from `ftue` to `messages:impl` module
* Update `SunsetPage` with light and dark modes
* Fix bloom colors when nested theme is used
* Integrate the migration screen in the room list
* Fix `WaitListView` cancel button color
* Clear migration store when removing the app's cache

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-02-08 10:01:08 +00:00
Benoit Marty
afc2e6c7fe Remove LogCompositions.
It was used at the beginning of the project, but is not useful anymore.
2024-02-07 16:33:48 +01:00
Benoit Marty
706ce1d0cd Do not use a key for the LazyColumn, or the scroll will not behave as expected if a room is moved to the top of the list. 2024-02-06 15:33:03 +01:00
bmarty
03c95555e3 Sync Strings from Localazy 2024-02-05 00:09:59 +00:00
Jorge Martín
5f064a4b27 Only display placeholder list when the room list hasn't loaded yet 2024-02-02 13:31:43 +01:00
Jorge Martín
02fe07a6bd Tweak room list behaviour:
- Instead of an extra item, use `contentPadding`.
- Make sure each item has an unique id.
2024-02-02 13:05:37 +01:00
Jorge Martín
e9c0aee96e Fix full placeholder screen 2024-02-02 13:04:56 +01:00
Jorge Martín
aa32123c82 Make the RoomListRoomSummaryFactory.createPlaceholder and RoomListRoomSummaryFactory.createFakeList functions static ones 2024-02-02 13:04:28 +01:00
Jorge Martín
49646f2bef Add an empty state to the room list.
- 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.
2024-02-02 12:39:09 +01:00
jmartinesp
f7abfb2f5a Sync Strings from Localazy 2024-01-31 11:38:48 +00:00
Benoit Marty
a7541be6bb
Merge pull request #2293 from element-hq/feature/bma/notificationCount
Iterate on notification badges
2024-01-30 10:33:17 +01:00
bmarty
7b0dcbe6a5 Sync Strings from Localazy 2024-01-29 00:09:56 +00:00
Benoit Marty
c5fc45e7fb Fix test compilation issue. 2024-01-25 17:22:10 +01:00
Benoit Marty
c7f29bfe8e Ensure the icon stay grey if the global setting is set to mention only.
Implement the iOS logic #2282
2024-01-25 16:17:27 +01:00
Benoit Marty
429effc706 Rework: improve OnGoingCallIcon API. 2024-01-25 15:29:11 +01:00
Benoit Marty
78bd91de2f Rework: extract sub fun composable. 2024-01-25 15:06:34 +01:00
Benoit Marty
6ea76d9acd Map roomInfo.numUnreadNotifications to RoomSummaryDetails.numUnreadNotifications 2024-01-25 15:00:43 +01:00
Benoit Marty
958e97f89c Make isTimestampHighlighted a computed val. 2024-01-23 11:20:10 +01:00
Benoit Marty
dd12071ea2 Use new Rust fields numUnreadMessages and numUnreadMentions, and iterate on the room badge rendering. 2024-01-22 15:48:46 +01:00
Benoit Marty
bbd871031a Fix detekt issue:
Use `?.let {}` instead of if/else with a null block when checking for nullable values [UseLet]
2024-01-22 14:21:49 +01:00
Benoit Marty
5caebaaa1b Introduce RoomListRoomSummaryFactory and remove RoomListRoomSummaryPlaceholders. 2024-01-22 11:29:54 +01:00
Benoit Marty
7832eb74b9 Remove default value for constructor of RoomListRoomSummary. 2024-01-22 11:11:44 +01:00
Benoit Marty
8eba12593b Ensure there is no timestamp in RoomListRoomSummary if lastMessage is null. 2024-01-22 11:05:25 +01:00
Benoit Marty
ed1112f09b Ensure roomId are unique in the list. 2024-01-22 11:02:45 +01:00
Benoit Marty
7fee884677 Use aRoomListRoomSummary function instead of invoking the constructor. 2024-01-22 11:02:13 +01:00
Benoit Marty
579f4d6a4e fun aRoomListRoomSummary: make internal, add all fields and reorder to match RoomListRoomSummary constructor order. 2024-01-22 10:59:42 +01:00
Benoit Marty
4924f86d3b Do not use the function for preview in test. 2024-01-22 10:49:19 +01:00
Benoit Marty
cf6bcca9cd Preview with a last message by default. 2024-01-19 17:59:18 +01:00
Benoit Marty
9d586bf2bb Improve aRoomListRoomSummary method. 2024-01-19 16:51:05 +01:00
Benoit Marty
782f73fb7c Remove notificationMode to userDefinedNotificationMode to match SDK name. 2024-01-19 16:46:42 +01:00
Benoit Marty
ecb000b8ed Remove hasOngoingCall to hasRoomCall to match SDK name. 2024-01-19 16:16:57 +01:00
Benoit Marty
be0da18a7b Rename userAvatarURLString to userAvatarUrl 2024-01-19 15:59:50 +01:00
Benoit Marty
d1c7520065 Rename avatarURLString to avatarUrl 2024-01-19 15:58:37 +01:00
Jorge Martin Espinosa
27f55c0bc4
Replace 'leave room' text with 'leave conversation' for DMs (#2231)
* Replace 'leave room' text with 'leave conversation' for DMs

* Add `isDm` property to both `RoomSummary` and `RoomListRoomSummary`

* Remove redundant `leave_conversation_alert_subtitle_*` texts

* Fix maestro flow

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-01-16 15:49:44 +01:00
ElementBot
6bc080c279
Sync Strings (#2230)
Co-authored-by: bmarty <bmarty@users.noreply.github.com>
2024-01-15 09:21:04 +01:00
Benoit Marty
5d086ad82d Fix moar ktlint issues 2024-01-11 10:02:10 +01:00
Benoit Marty
a831f05f6e Fix ktlint issues 2024-01-10 19:33:39 +01:00
renovate[bot]
c8bd362397
Update plugin ktlint to v12.1.0 (#2200)
* Update plugin ktlint to v12.1.0

* Run `./gradlew ktlintFormat` and fix some issues manually.

* Fix other issues reproted by Ktlint

* Limit false positives, KtLint removes unnecessary curly brace in String templates.

* Remove useless Unit

* Minor improvements over ktlint changes

* Restore `AlertDialogContent` behaviour

* Update screenshots

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Benoit Marty <benoit@matrix.org>
Co-authored-by: Jorge Martín <jorgem@element.io>
Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-01-10 16:22:24 +01:00
Benoit Marty
dd4aa681c6 Remove now useless ExperimentalLayoutApi opt in 2023-12-28 12:41:02 +01:00
bmarty
e6f4a7364f Sync Strings from Localazy 2023-12-26 09:39:48 +01:00
Jorge Martin Espinosa
cbf34929af
Revert "Room list badges" 2023-12-22 11:02:07 +01:00
Benoit Marty
91027f82e9 Fix test. 2023-12-21 16:11:03 +01:00
Benoit Marty
02fe9c4580 Handle PR review. 2023-12-21 16:05:51 +01:00
Benoit Marty
3a7804b3b0 We can have numUnreadMentions > 0 and numUnreadMessages == 0, in this case, display both icons. 2023-12-21 15:39:52 +01:00
Benoit Marty
f2c989cbd6 Iterate on indicators on room list #2079 2023-12-21 14:51:31 +01:00
Benoit Marty
c18959f0a0 Use VideoCallSolid and also delete local ic_video_call.xml icon. 2023-12-20 17:33:49 +01:00
Benoit Marty
fb766f5176
Merge pull request #2077 from element-hq/feature/bma/timestamp
Feature/bma/timestamp
2023-12-20 15:17:43 +01:00
Jorge Martin Espinosa
0e1d9e82f5
Font size on 'All Chats' was changing mid animation (#2073)
* Font size on 'All Chats' was changing mid animation
2023-12-20 13:52:19 +00:00
Benoit Marty
3d9fbe70d4 Fix timestamp font #2065 2023-12-20 11:42:29 +01:00