Commit Graph

160 Commits

Author SHA1 Message Date
Nicolas Mauri
54be55e4af Allow to record a voice message (#1926) 2023-10-23 15:47:36 +00:00
Mauro
04cce54c40 Send Intentional Mentions (#1929)
* updated sdks

* fix waveform

* implementation completed

* intentional mentions test

* removed unused var

* suggestion
2023-10-20 16:51:25 +03:00
Stefan Ceriu
af3d7f66d7 Implement support for ElementCall through Rust side widgets (#1906)
* Implement support for ElementCall through Rust side widgets

* Add Element Call feature flag

* Fix the unit tests

* Address PR comments
2023-10-17 12:41:56 +03:00
Nicolas Mauri
64f5122d32 Add UI to record a voice message from the composer toolbar (#1892) 2023-10-16 15:18:51 +00:00
Mauro
d0ea9ec66e Pills performance improvements (#1891)
* big performance improvement for pills

* small overall performance improvement

* code improvements
2023-10-13 14:40:18 +02:00
Alfonso Grillo
681565ee55 Remove ‘copy’ action for "media like" types (#1889)
* Remove ‘copy’ action when useless

* Delete unused property
2023-10-13 10:52:30 +00:00
Mauro
eed60f3c62 Completion Suggestion view for user mentions (#1859)
* created the list but I need to find a way to overlay it

* make the list able to have an intrinsic height

* best solution so far but does not work with expansion

* needs testing

* more scalable solution

* tests completed

* changelog

* injecting the media provider

* fix tests

* pr suggestions

* better testing
2023-10-06 15:47:31 +02:00
Nicolas Mauri
23768d141b Add voice message playback from the timeline (#1844) 2023-10-04 16:32:45 +00:00
Matthew Hodgson
4d820c20a4 Implement emotes (/me) (#1841)
* implement emotes (/me)

requires matthew/emotes branch of matrix-rust-sdk

* changelog + whitespace

* remove apparently superfluous swiftlint

* fix constness

* remove inout params and incorporate review

* switch to new api based on sdk PR feedback

* Bump the RustSDK to v1.1.21

* Address PR comments

---------

Co-authored-by: Stefan Ceriu <stefan.ceriu@gmail.com>
2023-10-03 16:17:03 +03:00
Mauro
38e824d74d @room pill (#1834)
* all users mention pill + red higlight for own mentions

* more tests

* changelog

* removed useless if let
2023-09-29 15:40:31 +02:00
Stefan Ceriu
c518a00d76 Add support for replying to events different than room messages 2023-09-27 08:28:46 +03:00
Alfonso Grillo
cf493657ce Add "end poll" confirmation dialog (#1799)
* Add poll end confirmation dialog

* Fix button role in CreatePollScreenViewModel
2023-09-26 12:57:40 +00:00
Alfonso Grillo
c25134a5b2 Add polls "creator view" (#1765)
* Add end button in PollRoomTimelineView

* Add creator logic

* Refine PollRoomTimelineView previews

* Add UI tests

* Update preview tests
2023-09-21 14:59:17 +00:00
Nicolas Mauri
ec76c2973f Add voice message rendering to the timeline (#1776) 2023-09-21 14:36:21 +00:00
Alfonso Grillo
9b7f94436f Improve message edit with RTE (#1742)
* Improv edit for RTE

* Refine code block style in composer

* Update matrix-wysiwyg-composer-swift to 2.13.0

* Remove workaround

* Update ElementX/Sources/Services/Timeline/TimelineItems/Items/Messages/TextRoomTimelineItemContent.swift

Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>

* Refactor rawFormattedBody -> formattedBodyHTMLString

---------

Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>
2023-09-21 13:45:43 +00:00
Stefan Ceriu
8ef51d4f10 Prevent mapping members on the main queue inside the room screen view model 2023-09-20 15:09:29 +03:00
Stefan Ceriu
f045793b36 Disable reply actions for local echoes 2023-09-19 17:39:04 +03:00
Mauro
63fc9ad410 Thread Decorator (#1686)
* just added the isThreaded property to message based events

* done but I should add a bunch of tests for images and videos and locations

* handling for image and videos, but locations might need to be double checked

* code improvement

* better tests and removed code that is not used, we need to fix first the appearence of replies

* bubble style is solved, we now need plain style

* also added plain style

* better handling for bubble style

* rounded corner only for bubbles in location

* fix for wrong aspect ratio in replies

* all changes done

* better testing

* swift format

* changelog

* PR comments and rebase.

* Simplify corner radius on location timeline view.

---------

Co-authored-by: Doug <douglase@element.io>
2023-09-15 11:58:30 +01:00
Alfonso Grillo
c28b94c61e Move RTE feature flag to settings (#1703)
* Update matrix-wysiwyg-composer-swift to 2.10.1

* Delete MessageComposerTextField

* Always use rte composer

* Fix corner radius

* Cleanup
2023-09-14 13:10:42 +02:00
Stefan Ceriu
1a438c176f Fixes #1699 - Introduce a new advanced settings screen (#1700) 2023-09-14 08:37:42 +03:00
Alfonso Grillo
cb5173c4a3 Add polls analytics (#1691)
* Refactor location events

* Add poll analytics
2023-09-13 09:28:44 +02:00
Stefan Ceriu
d182b85996 Fixes #1338 - Add copy permalink option for messages that failed decryption 2023-09-11 16:58:23 +03:00
Stefan Ceriu
b6ea17c535 Top level deeplink handling (#1660)
* Handle link opening on the top most levels and prepare for percolating them throughout the app
* Add support for a custom app scheme
* Add specific AppRoute parsers.
* Integrate custom scheme in the AppRouteURLParser
* Switch to `element://call` and cleanup route parsing
2023-09-11 12:31:31 +03:00
Alfonso Grillo
0381fe3ce5 Polls refinements (#1608)
* Refine focus behavior

* Begin draft mode

* Add alert on poll form

* Add poll ended asset

* Add fallback text for ended poll event

* Cleanup

* Fix assets

* Remove poll feature flags

* Fix UI tests

* Fix ui tests

* Refine discard poll alert

* Remove unused import

* Rename hasDraftContent -> hasContent

* Restore createPoll-2 ref screenshots
2023-09-01 15:55:11 +02:00
Alfonso Grillo
3accdb9898 Vote on a poll and end a poll (#1597)
* Fix project file

* Add vote and end poll actions

* Handle redaction

* Fix local echo behavior

* Cleanup

* Fix UI tests

* Add localisation

* Cleanup

* Fix end poll action style
2023-08-31 12:04:25 +02:00
Alfonso Grillo
fccabd6470 Create poll UX (#1571)
* Add poll attachment button

* Add poll creation feature flag

* Setup navigation to CreatePollScreen

* Add create/cancel actions

* Add create poll screen ui skeleton

* Add bindings in CreatePollScreen

* Add logics in CreatePollScreen

* Cleanup code

* Fix option deletion crash

* Fix conflicts

* Add create poll logic

* Add localisations

* Fix test build errors

* Fix crash

* Add UTs

* Add accessibility IDs

* Add ui tests

* Add 240 char limit

* Fix addOption hide behavior

* Add maxNumberOfOptions

* Cleanup code

* Move delete workaround in the view model

* Use compound delete icon
2023-08-30 09:23:30 +00:00
aringenbach
cddacbc146 Initial integration of RTE (#1464)
* Initial integration of RTE

* Fix `clipped`, `focused` and composer view type

* Remove horizontal padding

* Add `ComposerToolbar` mock

* Restore `composerFocusedSubject`

* Allow using HTML from RTE on message sent

* Fix new message content API

* Add feature flag for Rich Text Editor
2023-08-29 12:37:13 +00:00
Stefan Ceriu
6397b127a4 Register for room info updates 2023-08-29 12:33:25 +03:00
Alfonso Grillo
8d5ee49e6d Refine polls UI in the timeline (#1474)
* Add summary view in PollRoomTimelineView

* Add selectedPollOption action

* Handle undisclosed polls

* Add more logics in PollRoomTimelineView

* Refine ended poll UI

* Refine poll layout

* More UI refinements

* Fix layout issue

* Refine progress bar

* Add poll mocks and UI tests

* Cleanup
2023-08-11 10:25:16 +00:00
Stefan Ceriu
0a58fbfeac Fixes #1140 - Dismiss all modals when presenting a room 2023-08-10 15:19:43 +03:00
aringenbach
b077e0fd38 Extract composer toolbar to a dedicated component (#1427)
* Extract composer toolbar to a dedicated component

* Use publisher for composer mode

* Introduce `RoomScreenComposerProvider`

* Add `ComposerToolbarViewModelTests`

* Rename protocols and add passthrough subjects for focused and composer mode

* Remove `ComposerToolbarViewActionHandler` and `ComposerToolbarCoordinatorParameters`

* Remove `RoomScreenComposerActionHandlerProtocol` and `RoomScreenComposerProviderProtocol`

* Re-arrange code a bit

* Remove composer mode being stored on `RoomScreen`

* Rename `process(viewAction: ComposerToolbarViewAction)` to `process(composerAction: ComposerToolbarViewAction)`

* Replace PassthroughSubject with direct function call

* Remove `ComposerToolbarCoordinator`

* Remove `cancelEdit` and `cancelReply` from external composer view model actions

* Use `RoomScreenComposerAction` as a sub-`RoomScreenViewModelAction`

* Move `ComposerToolbarViewModel` callback to actionsSubject

* Move `RoomScreenViewModel` callback to actionsSubject

* Fix `RoomScreenViewModelTests`

* Rename `composerAction` parameter to `roomAction`

* Fix unit tests
2023-08-08 14:25:23 +02:00
Stefan Ceriu
127e7f29a6 Tweak swiftlint settings 2023-08-08 11:48:40 +03:00
Stefan Ceriu
fcb4a22079 Fixes #1455 - Use the stable timeline id to match timeline items in between local echo and remote echo states 2023-08-08 11:48:40 +03:00
Doug
404af0763a Send read receipts as messages are displayed. (#1426) 2023-08-01 11:53:02 +01:00
Doug
553c96521f Fix a bug when dismissing a media preview. (#1428) 2023-08-01 10:45:42 +01:00
David Langley
ea691f718a Highlight selected emoji in picker, correct add more button in menu, fix order of count label on outgoing messages (#1430)
- Highlight selected emoji in picker
- Correct add more button in menu
- Fix the order of count/key label on outgoing messages
- Fix the size padding of emoji in reactions
2023-08-01 08:59:10 +01:00
Stefan Ceriu
86a1097540 Fix unit tests 2023-07-31 14:29:40 +03:00
Stefan Ceriu
58da19c42b Enable all room summary provider logs to track down duplicated room list item problems 2023-07-31 14:29:40 +03:00
Stefan Ceriu
ccb78a9ae5 Delay rendering bottom timeline items when scrolled up and avoid content shifts
- builds on top of langleyd/timeline_defer_new_items
- improve animations
2023-07-31 14:29:40 +03:00
Mauro
08785683f5 Reverting to TableView but with SwiftUI compatibility (#1407)
* revert but also allows us to keep the existing SwiftUI implementation if we need it

* code improvement

* pr review

* FF is volatile

* message that communicates that is volatile
2023-07-26 13:53:43 +00:00
Mauro
54420f5989 SwiftUI timeline refactor + TimelineViewState decoupling (#1392)
* swiftUI conversion + scroll to bottom

* remove unused

* back pagination implemented, however when a lot of elements are in the scroll the perfomance diminishes not sure what may be causing it

* scroll adapter solution

* way better

* works but height animation in cells are broken

* code improvement

* everything implemented

* rebase fix

* fix

* doc

* fix test compilation

* code improvement and animation improvement

* code improvement

* code improvements

* tests updated.

* pr comments

* better identifiers

* fix

* some PR comments

* pr comments
2023-07-25 12:20:13 +00:00
Doug
f47ccc1ae1 Tweaks for macOS (#1383)
* Fix constant Create Room button animation on macOS.

* Allow right-clicking on timeline items to work again on macOS.

* Use inline media upload previews on macOS

This comes with the caveat that the previews are no longer interactive.
2023-07-24 12:08:50 +00:00
Alfonso Grillo
051e1f29a0 Remove ”copy” action for location events (#1355)
* Hide ”copy” action for location events

* Cleanup
2023-07-18 15:54:42 +00:00
Mauro
7557baf30a Redacting is now displayed for moderators in groups (#1324)
* basic implementation

* sdk update

* format

* changelog
2023-07-18 13:51:27 +00:00
Mauro
a3671e9685 SDK Changes Refactor (#1312)
* internal id

* notification refactor

* client proxy refactor

* required self

* better identifier system

* using the event id when required

* tests fixed

* tested some stuff

* fixed merge conflict

* improved the test wait

* animation disabled

* Bump Rust SDK version to 1.0.98-alpha (#1310)

* code improvement

* pause sync

* pr suggestions

* result

* Apply suggestions from code review

Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>

* enum based debug identifier

---------

Co-authored-by: aringenbach <80891108+aringenbach@users.noreply.github.com>
Co-authored-by: Doug <6060466+pixlwave@users.noreply.github.com>
2023-07-12 10:28:41 +00:00
Mauro
66448921da Removing Delivered Notifications (#1305)
* completed

* changelog

* tests

* more tests

* better naming

* fix

* a bit more waiting time

* generated mocks

* xcodegen
2023-07-11 10:44:06 +02:00
David Langley
3b03b711a7 Add expand/collapse UI for reactions (#1249)
* Add expand/collapse UI for reactions

- Adds a CollapsibleFlowLayout for controlling the layout
- Adds tests for  this layout and some mocks for testing layouts generally
- Improves the rendering of the reaction buttons which were not pixel perfect
- Adds the UI for the expand collapse buttons including the count of hidden items in the collapsed state.

* Add comment for reactionsCollapsed binding.

* Remove Flow and simplify implementation

- Remove SwiftUI-Flow
- Add strings by importing from Localyse
- Remove count on expand button as requires GeometryReader and can cause loops
- Don't use GeometryReader for hiding reactions with opacity(just put them way off screen for now)
- Fix unit and UI tests

* Address PR comments

- use synthesized inits
- use rows rather than lines for naming flow layout
- other naming improvements
- reactions were already rendered in another ui test, removing my test on favour of those and updating the screenshots for those.
2023-07-10 15:13:58 +00:00
Mauro
d8331ce5b9 Refactor the NSDiffableDataSourceLayer (#1235)
* first part, using references

* better animations

* delete view provider and replaced wth two files

* ordered dictionary usage

* bubbled styler view previews

* plain style is back

* fix

* read marker previews restored

* updated tests

* code improvements

* better naming
2023-07-04 14:08:43 +00:00
Alfonso Grillo
5cf41347ca Update SDK to 1.0.94-alpha (#1232)
* Update SDK

* Map new location fields

* Add LocationRoomTimelineItemContent.AssetType
2023-07-04 06:39:32 +00:00
Stefan Ceriu
924fd166b1 Fixes #954 - Implement media upload cancelling 2023-06-29 13:32:42 +03:00