Commit Graph

521 Commits

Author SHA1 Message Date
ElementBot
e2f6346b44 Update screenshots 2023-10-27 08:51:51 +00:00
Marco Romano
a67560c74b Convert mx waveform to floats as early as possible in the chain (#1652)
This way we're sure that internally we always deal with [0;1] float samples. the [0;1024] int range is used only at the rust sdk boundary.
2023-10-26 16:58:00 +00:00
jonnyandrew
517b422992 Add voice message preview player (#1646)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-26 15:33:58 +00:00
jonnyandrew
8258bdcf80 Move waveform UI to design system library (#1649) 2023-10-26 15:15:42 +00:00
ganfra
35d32c0500 Merge pull request #1642 from vector-im/feature/fga/pin_settings
PIN : settings and branch flow
2023-10-26 16:40:38 +02:00
Jorge Martin Espinosa
c40a39bbfa Update the chat screen UI using RoomInfo. (#1640)
* Update the chat screen UI using `RoomInfo`.

This is specially useful for getting live values for `hasRoomCall`.

* Ensure the first `MatrixRoomInfo` is emitted ASAP

* Try excluding `*Present$present$*` inner functions from kover as separate entities

* Update strings

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-26 14:27:42 +00:00
ElementBot
27d4cab217 Update screenshots 2023-10-26 13:45:59 +00:00
ElementBot
537068cb32 Update screenshots 2023-10-26 09:32:15 +00:00
ElementBot
d95a616f36 Update screenshots 2023-10-26 08:26:46 +00:00
Marco Romano
e2a40c8bd1 Voice message bubble design improvements (#1637)
- Fixes color and size of both text and icons.
2023-10-25 17:33:50 +02:00
David Langley
86cd274b3a Merge pull request #1610 from vector-im/dla/feature/custom_room_notification_settings_list
Custom room notification settings list
2023-10-24 23:02:16 +01:00
Marco Romano
3b20120705 Receive and play a voice message (#1503)
## Type of change

- [x] Feature
- [ ] Bugfix
- [ ] Technical
- [ ] Other :

## Content

This PR consists of several macro-blocks separated by path/package:
- `messages.impl.mediaplayer` : Global (room-wide) media player, now used only for voice messages but could be used for all media within EX in the future. It is backed by media3's exoplayer. Currently not unit-tested because mocking exoplayer is not trivial.
- `messages.impl.voicemessages.play` : Business logic of a timeline voice message. This is all the logic that manages the voice message bubble.
- `messages.impl.timeline.model` & `messages.impl.timeline.factories`: Timeline code that takes care of creating the `content` object for voice messages.
-  `messages.impl.timeline.components` : The actual View composable that shows the UI inside a voice message bubble.

All the rest is just small related changes that must be done here and there in existing code.

From a high level perspective this is how it works:
- Voice messages are unlike other message bubbles because they carry state (i.e. playing, downloading...) so they have a Presenter managing this state.
- Media content (i.e. the ogg file) of a voice message is downloaded from the rust SDK on first play then stored in a voice messages cache (see the `VoiceMessageCache` class, it is just a subdirectory in the app's cacheDir which is indexed by the matrix content uri). All further play attempts are done from the cache without hitting the rust SDK anymore.
- Playback of the ogg file is handled with the `VoiceMessagePlayer` class which is basically a "view" of the global `MediaPlayer` that allow the voice message to only see the media player state belonging to its media content. 
- Drawing of the waveform is done with an OSS library wrapped in the `WaveformProgressIndicator` composable.

Known issues:
 - The waveform has no position slider.
 - The waveform (and together with it the whole message bubble) is taller than the actual Figma design.
 - Swipe to reply for voice messages is disabled to avoid conflict with the audio scrubbing gesture (to reply to a voice message you have to use the long press menu).
 - The loading indicator is always shown (there is no delay).
 - Voice messages don't stop playing when redacted.

## Motivation and context

https://github.com/vector-im/element-meta/issues/2083

## Screenshots / GIFs

Provided by Screenshot tests in the PR itself.
2023-10-24 21:47:51 +00:00
ElementBot
cf1d4cf087 Update screenshots 2023-10-24 21:31:36 +00:00
David Langley
c61d2d3941 Merge branch 'develop' into dla/feature/custom_room_notification_settings_list 2023-10-24 22:18:38 +01:00
jonnyandrew
98b75424a8 Allow deleting a recorded voice message (#1635)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-24 21:02:19 +00:00
ElementBot
bc4f67c277 Update screenshots 2023-10-24 16:35:20 +00:00
David Langley
e388ea21b6 Merge branch 'develop' into dla/feature/custom_room_notification_settings_list 2023-10-24 17:20:15 +01:00
ElementBot
1948414566 Update screenshots 2023-10-24 17:17:15 +02:00
jonnyandrew
9046ac4c8a Add voice message recording duration indicator and limit (#1628)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-24 11:44:53 +00:00
jonnyandrew
bdc52332bb Add progress indicator for sending voice messages (#1618)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-24 08:36:42 +00:00
jonnyandrew
5c582bba1b Record and send voice messages (#1596)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-23 17:28:00 +00:00
ganfra
40f677192a Merge pull request #1624 from vector-im/feature/fga/pin_auth_ui
PIN : unlock screen ui
2023-10-23 16:35:22 +02:00
ElementBot
733b9c4ab1 Update screenshots 2023-10-23 13:49:14 +00:00
Benoit Marty
e49c0c46eb Konsist: add test to ensure that functions with @PreviewsDayNight are internal, and fix existing issues. 2023-10-23 12:23:27 +02:00
Benoit Marty
577527902f Konsist: add test to ensure that functions with @PreviewsDayNight contain ElementTheme composable, and fix existing issues. 2023-10-23 12:23:27 +02:00
ElementBot
46bfbc06fa Sync Strings (#1623)
* Sync Strings from Localazy

* Fix strings

* Update screenshots

---------

Co-authored-by: bmarty <bmarty@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2023-10-23 08:20:49 +00:00
ElementBot
68ff7c5e7b Update screenshots 2023-10-23 08:15:26 +00:00
ElementBot
e718c452c5 Update screenshots 2023-10-20 20:30:14 +00:00
ElementBot
1b9cc7ded5 Update screenshots 2023-10-20 09:12:23 +00:00
ElementBot
e38ce7d9e0 Update screenshots 2023-10-19 20:39:07 +00:00
ganfra
833bff9ba9 Merge branch 'develop' into feature/fga/pin_create_ui 2023-10-19 22:26:21 +02:00
ElementBot
919e0d7301 Update screenshots 2023-10-19 15:47:25 +00:00
Jorge Martin Espinosa
5e547269e7 Integrate Element Call with widget API (#1581)
* Integrate Element Call with widget API.

- Add `appconfig` module and extract constants that can be overridden in forks there.
- Add an Element Call feature flag, disabled by default.
- Refactor the whole `ElementCallActivity`, move most logic out of it.
- Integrate with the Rust Widget Driver API (note the Rust SDK version used in this PR lacks some needed changes to make the calls actually work).
- Handle calls differently based on `CallType`.
- Add UI to create/join a call.

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-19 15:38:43 +00:00
ElementBot
1c1db6a444 Update screenshots 2023-10-19 15:24:30 +00:00
ganfra
bde2705654 Pin create: add test for presenter 2023-10-19 15:45:11 +02:00
ElementBot
537fc68778 Update screenshots 2023-10-19 10:47:03 +00:00
ganfra
988b6243d1 Merge pull request #1592 from vector-im/feature/fga/setup_crypto_for_pin
Feature/fga/setup crypto for pin
2023-10-18 17:21:47 +02:00
ElementBot
441b469dc5 Update screenshots 2023-10-18 13:22:53 +00:00
Jorge Martin Espinosa
7e2852bd47 Make sure Konsist tests always run (#1590)
* Make sure Konsist tests always run

* Update tests/konsist/build.gradle.kts

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

---------

Co-authored-by: Benoit Marty <benoit@matrix.org>
2023-10-18 09:41:47 +00:00
Benoit Marty
155e403265 Fix issue detected by Konsist. 2023-10-13 15:44:34 +02:00
ganfra
c6a6ccc844 Merge pull request #1554 from vector-im/feature/fga/init_pin_unlock
[Pin code] : setup the feature
2023-10-13 12:38:41 +02:00
Benoit Marty
41c8d6510f Fix warning
Name contains characters which can cause problems on Windows: "
2023-10-12 18:44:33 +02:00
Benoit Marty
bdd7ecd789 Move konsist test to their own module. 2023-10-12 18:41:38 +02:00
jonnyandrew
ffa6c43503 [Voice messages] Add voice recording UI (#1546)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-12 15:17:18 +00:00
ElementBot
17c12899f5 Update screenshots 2023-10-12 10:45:08 +00:00
Benoit Marty
305fb81b8a Merge pull request #1520 from vector-im/feature/bma/sessionDb
Improve session db and improve deleted session behavior
2023-10-11 16:56:54 +02:00
ElementBot
7607f4f07b Update screenshots 2023-10-10 19:18:36 +00:00
ElementBot
22fa3dff15 Update screenshots 2023-10-10 15:52:14 +00:00
jonnyandrew
7e91e7824e Refactor composer UI components to separate files (#1506)
---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2023-10-10 08:31:36 +00:00
Marco Romano
182511d92c Optimize use of blurhash algo in bloom modifier (#1509)
- Reduced to 20px the size of the bitmap we encode the blurhash from.
- Reduced the blurhash components from 5 to 4.

As per suggestions in: https://github.com/woltapp/blurhash#good-questions
2023-10-09 16:24:37 +02:00