Commit Graph

128 Commits

Author SHA1 Message Date
renovate[bot]
6d3b816bf5 Update dependency app.cash.molecule:molecule-runtime to v1 (#925)
* Update dependency app.cash.molecule:molecule-runtime to v1

* Replace `RecompositionClock` with `RecompositionMode`

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2023-07-20 07:36:19 +02:00
Benoit Marty
d5e6bbbe05 Show Sync status when state is Terminated. 2023-07-19 14:57:10 +02:00
Benoit Marty
c04fcfc352 Make SyncState values match SyncServiceState values. 2023-07-19 14:44:53 +02:00
Benoit Marty
1f243dcb54 Ensure uitest take preview from appnav module. 2023-07-19 14:41:41 +02:00
Benoit Marty
f8fd684710 Implement SyncState chip. (#909) 2023-07-19 12:30:34 +02:00
ganfra
c7d0bbc174 Merge pull request #906 from vector-im/feature/fga/update-rust-sdk-0.1.34
Feature/fga/update rust sdk 0.1.34
2023-07-18 22:52:48 +02:00
Marco Romano
78773b68e7 Make the functions in SystemUtils extensions (#899)
- They are now all extensions over `Context` or `Activity` (when `Context` is not enough) (some of them already were).
- Allows for IDE completion.
2023-07-18 13:11:11 +00:00
ganfra
1a9f0732e1 Merge branch 'develop' into feature/fga/update-rust-sdk-0.1.32 2023-07-18 10:12:19 +02:00
ganfra
ae3c0c7e32 RoomFlowNode: use newRoot instead of safeRoot as in this case it can create a race condition where we end up not switching node 2023-07-17 23:27:18 +02:00
ganfra
c7406de5e2 Update rust sdk : start branching new SyncService (wip) 2023-07-17 22:26:21 +02:00
Benoit Marty
b15484933d Merge branch 'develop' into fix/jme/880-sliding-sync-loop-expires-and-restarts 2023-07-17 22:18:59 +02:00
ganfra
98131d3046 MatrixClientHolders: some more cleanup 2023-07-17 21:32:07 +02:00
ganfra
9846db6338 Rework a bit MatrixClientHolder and reintroduce cacheIndex... 2023-07-17 18:34:50 +02:00
Jorge Martin Espinosa
280b7e32e0 Hide encryption history + FTUE flow (#839)
* First attempt at implementing encrypted history banner and removing old UTDs

* Get the right behavior in the timeline

* Implement the designs

* Extract post-processing logic, add tests

* Add encryption banner to timeline screenshots

* Create FTUE feature to handle welcome screen and analytics

* Move classes to their own packages, add tests for `DefaultFtueState`.

* Remove unnecessary private MutableStateFlow

* Move some FTUE related methods and classes back to the `impl` module

* Handle back press at each FTUE step

* Remove unneeded `TestScope` receiver for `createState` in tests.

* Use light & dark previews for the banner view.

* Move color customization from `TextStyle` to `Text` component.

* Rename `InfoList` design components, use them in `AnalyticsOptInView` too.

* Cleanup MatrixClient.

* Fix copy&paste error

Co-authored-by: Benoit Marty <benoit@matrix.org>

* Fix typo

* Fix Maestro tests

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
Co-authored-by: Benoit Marty <benoit@matrix.org>
2023-07-17 18:34:36 +02:00
Jorge Martin Espinosa
e61af2eb7d Fix: make sure we ignore notifications for open rooms (#867)
* Make sure we ignore notifications for open rooms
- Listen to process lifecycle changes in `AppForegroundStateService`. Use initializers to reliable create it.
- Merge `AppNavigationState` with `AppForegroundState`. Renamed the previous `AppNavigationState` to `NavigationState`, created a new `AppNavigationState` which contains both the navigation state and the foreground state.
2023-07-17 17:02:06 +02:00
Jorge Martín
ded1518f0b Try to centralise session restoration through MatrixClientsHolder 2023-07-17 15:05:13 +02:00
Jorge Martín
d69dea6608 Fix sliding sync loop restarts due to expirations
Both `NotifiableEventResolver` and `DefaultNotificationDrawerManager` were creating new Rust SDK Clients while processing notifications instead of reusing the already existing one.
2023-07-17 08:05:12 +02:00
Benoit Marty
8893a8bfdc Fix crash at first startup. Inject NotLoggedInImageLoaderFactory directly to NotLoggedInFlowNode 2023-07-12 15:32:00 +02:00
Benoit Marty
c0d2de26db Improve logs. 2023-07-12 12:39:41 +02:00
Benoit Marty
a9720e36c1 Let RootFlowNode manage MatrixClientsHolder save and restoration. 2023-07-12 12:25:04 +02:00
Benoit Marty
93c918ea2a Fix image not loading after a clear cache. 2023-07-12 12:05:31 +02:00
Benoit Marty
7ea2f28d96 More log about Node lifecycle. Will help to track user navigation. 2023-07-12 12:01:54 +02:00
Benoit Marty
5f3ba74f30 Remove fontSize parameter. Must use style only. 2023-07-10 17:33:42 +02:00
ganfra
28db48540c Merge pull request #816 from vector-im/feature/fga/fix_loading_room_node_padding
LoadingRoomNode : fix windowInsets...
2023-07-10 15:49:51 +02:00
ganfra
5d1be53ff4 RoomNodeView: remove contentWindowInsets=systemBars as it's default one 2023-07-10 15:33:32 +02:00
ganfra
8af99fe280 LoadingRoomNodeView: ConsumeWindowInsets... 2023-07-10 15:13:32 +02:00
Jorge Martin Espinosa
9170c5eb71 Display room invitation notification (#735)
* Notifications: Add some extra mappings so we keep the original contents and can pass it later to an UI layer

* Fix notifications not appearing for a room if the app was on that room when it went to background.

* Modernize how we create spannable strings for notifications, remove unneeded dependency

* Remove actions from invite notifications temporarily

* Add `NotificationDrawerManager` interface to be able to clear membership notifications when accepting or rejecting a room invite

* Fix tests

* Add comment to clarify some weird behaviours

* Address review comments

* Set circle shape for `largeBitmap` in message notifications

* Fix no avatar in DM rooms

* Fix rebase issues

* Add invite list pending intent:

- Refactor pending intents.
- Make `DeepLinkData` a sealed interface.
- Fix and add tests.

* Rename `navigate__` functions to `attach__`

* Add an extra test case for the `InviteList` deep link

* Address most review comments.

* Fix rebase issue

* Add fallback notification type, allow dismissing invite notifications.

Fallback notifications have a different underlying type and can be dismissed at will.

* Fix tests
2023-07-10 14:34:58 +02:00
Jorge Martin Espinosa
10d5ada93d Remove extra syncService.startSync() call (#830) 2023-07-10 10:45:02 +02:00
ganfra
e94295bef8 LoadingRoomNode : fix windowInsets... 2023-07-07 14:16:52 +02:00
Benoit Marty
2347c815a7 Merge pull request #811 from vector-im/feature/bma/verificationSnackbar
Display the "verification success" Snackbar only when the state is `VerificationFlowState.Finished`.
2023-07-07 14:12:52 +02:00
ganfra
da27970116 Merge branch 'develop' into feature/fga/waiting_ss_room 2023-07-07 11:34:45 +02:00
ganfra
f780e71026 Await room: add tests on LoadingRoomStateFlowFactory 2023-07-07 11:32:23 +02:00
Benoit Marty
17a0c7b865 Display the "verification success" Snackbar only when the state is VerificationFlowState.Finished.
Apply the same fix for `displayLeftRoomMessage`
2023-07-07 10:23:08 +02:00
ganfra
b2232fdd37 Merge branch 'develop' into feature/fga/app_nav_node_fixes 2023-07-06 18:37:02 +02:00
ganfra
5c41f0188a Node: rework LoggedInFlowNode analytics pop 2023-07-06 18:12:45 +02:00
ganfra
b72313bc84 Nodes: rework RootFlowNode with cache service 2023-07-06 18:08:29 +02:00
Benoit Marty
a2e04f7dc2 Use a val for the StateFlow, and expose a StateFlow. 2023-07-06 17:25:02 +02:00
ganfra
b953fb5cbb Room: add network monitor in LoadingRoomView 2023-07-06 12:24:20 +02:00
ganfra
4aafddebac Room : rename the flows 2023-07-06 12:00:45 +02:00
Benoit Marty
7e237977eb Show the "You're in" screen 2023-07-06 11:48:06 +02:00
ganfra
1fd493a76c Room : small refactoring 2023-07-05 16:10:47 +02:00
Marco Romano
f33561c25d Revert "Auto generate dark mode previews and screenshots (#776)" (#784)
This reverts commit 79b529193c.
2023-07-05 15:47:53 +02:00
Marco Romano
79b529193c Auto generate dark mode previews and screenshots (#776)
With this change, composable previews and screenshots should be created with just:
```
@ElementPreviews
@Composable
fun MyViewPreview() {
    ElementPreview { 
        MyView()
    }
}
```

- Adds `@ElementPreviews` which is a shorthand for:
```
@Preview(name = "D")
@Preview(name = "N", uiMode = Configuration.UI_MODE_NIGHT_YES)
```
Should be used in connection with the now public `fun ElementPreview()` composable.

- Adds ElementPreviews to previewAnnotations in dangerfile
- Screenshots of night mode previews are now rendered with night mode
- Replaces `ElementPreviewLight` and `ElementThemedPreview` with `ElementPreview`
- Deprecates `ElementPreviewDark` which should be removed.
- Remaining usages of `ElementPreviewDark` are now ignored during screenshot tests
2023-07-05 13:58:24 +02:00
ganfra
8667784271 AwaitRoom : create loading state with placeholders 2023-07-05 12:42:01 +02:00
ganfra
79eef06995 Await room: first attempt to wait for a room to be ready 2023-07-04 18:19:06 +02:00
Benoit Marty
acec682dee Add "Complete verification" item in the root setting screen. 2023-07-03 17:09:04 +02:00
ganfra
16f95cac16 Room lifecycle: fix close room crash 2023-06-29 19:41:47 +02:00
ganfra
e3744636b6 Merge branch 'develop' into feature/fga/room_list_api 2023-06-28 15:14:06 +02:00
Benoit Marty
82e566175a Room list: tweak UI and add overflow menu with report bug and invite friends action.
Extract invite friends action to a use case to avoid copy paste.
2023-06-27 19:23:37 +02:00
ganfra
2a24d0196e Merge branch 'develop' into feature/fga/room_list_api 2023-06-27 10:47:50 +02:00