Previously we were watching for changes to the room state to know when you become connected to a call. However, the room state might not change if you had a stuck membership event prior to re-joining the call. It's going to be more reliable to watch for the 'join' action that Element Call sends, and use that to track the connection state.
* InviteDialog: show some words and a spinner while invites are being sent
* MultiInviter-test: avoid building unhandled rejected promises
If we don't handle rejected promises, jest gets confused by them. Instead,
let's create them on-demand.
* Open a "progress" dialog while invites are being sent
* Inhibit invite progress dialog when RoomUpgradeWarning dialog is kept open
... otherwise the `RoomUpgradeWarning` dialog disappears during the invites,
and the tests that assert that it is showing the correct thing fail.
enter the commit message for your changes. Lines starting
* Switch to compound CSS variables instead of old pcss vars
* update playwright screenshots
* Revert "update playwright screenshots"
This reverts commit b0a15d97f35a088fe5b67009085eab46be1316fd.
* Another go at updating screenshots
* Address review comments
* remove redundant Props
* Move Room List to ListView
- Also remove Space/Enter handing from keyboard navigation we can just leave the default behaviour of those keys and handle via onClick
* Update rooms when the primary filter changes
Otherwise when changing spaces, the filter does not reset until the next update to the RVS is made.
* Fix stickyRow/scrollIntoView when switiching space or changing filters
- Also remove the rest of space/enter keyboard handling use
* Remove the rest of space/enter keyboard handling use
* Remove useCombinedRef and add @radix-ui/react-compose-refs as we already depend on it
- Also remove eact-virtualized dep
* Update RoomList unit test
* Update snapshots and unit tests
* Fix e2e tests
* Remove react-virtualized from tests
* Fix e2e flake
* Update more screenshots
* Fix e2e test case where were should scroll to the top when the active room is no longer in the list
* Move from gitpkg to package-patch
* Update to latest react virtuoso release/api.
Also pass spaceId to the room list and scroll the activeIndex into view when spaceId or primaryFilter change.
* Use listbox/option roles to improve ScreenReader experience
* Change onKeyDown e.stopPropogation to cover context menu
* lint
* Remove unneeded exposure of the listView ref
Also move scrollIntoViewOnChange to useCallback
* Update unit test and snapshot
* Fix e2e tests and update screenshots
* Fix unit test and snapshot
* Update more unit tests
* Fix keyboard shortcuts and e2e test
* Fix another e2e and unit test
* lint
* Improve the naming for RoomResult and the documentation on it's fields meaning.
Also update the login in RoomList to check for any change in filters, this is a bit more future proof for when we introduce multi select than using activePrimaryFilter.
* Put back and fix landmark tests
* Fix test import
* Add comment regarding context object getting rendered.
* onKeyDown should be optional
* Use SpaceKey type on RoomResult
* lint
* Hide recovery key when asked to re-enter it when creating or changing key
* Use align-self to centre the eye icon
Co-authored-by: R Midhun Suresh <hi@midhun.dev>
* Use CSS vars for padding
Co-authored-by: R Midhun Suresh <hi@midhun.dev>
* Use CSS classes to avoid needing the highly specific rule
* Use a Compound variable for border width
* Add classes to snapshots
* Update screenshots
---------
Co-authored-by: R Midhun Suresh <hi@midhun.dev>
* Move `inviteUsersToRoom` to `RoomUpgrade`
This method is only used in one place, uses only public methods, and is
undocumented. Let's move it to the place where it is used, to simplify the API
for `RoomInvite`.
* Simplify `inviteUsersToRoom`
`inviteMultipleToRoom` basically never throws, so this code was effectively
unreachable.
* Update MultiInviter to take an options object
I'm going to add another option, so an options object is going to be more
flexible.
* Jump through the coverage hoop with another test
* Remove NoOneHere disabled reason.
This was used to prohibit starting calls if the user is alone in the room.
Since there are currently issues with the user count calculation this can disable the button even when not appropriate.
On top of that, there is a reason to start a call if the room was just created and the user is still waiting for the others to join the room to then join the call.
Signed-off-by: Timo K <toger5@hotmail.de>
* some ci fixes
Signed-off-by: Timo K <toger5@hotmail.de>
* fix test snapshots
Signed-off-by: Timo K <toger5@hotmail.de>
* fix test to expect enabled call buttons
* Update snapshot for unit-tests/components/views/rooms/RoomHeader/RoomHeader-test.tsx
---------
Signed-off-by: Timo K <toger5@hotmail.de>
Co-authored-by: fkwp <github-fkwp@w4ve.de>
* Fix downloading files with authenticated media API
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Update snapshot
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Fix test
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
---------
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Add `?no_universal_links=true` to OIDC cb url so EX doesn't try to handle it
This is specific to macOS and only affects cases where auth is attempted in the non-default browser
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Strip no_universal_links after auth
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Update MAS
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Update playwright-common
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Iterate
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Iterate
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Bump @element-hq/element-web-playwright-common
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Tests
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
---------
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Show a blue lock instead of a grey shield for unencrypted rooms
* Update screenshots and snapshot
* Update snapshots and fix e2e test that used to expect the grey shield
* lint and add tests for shield
* Update more screen shots
* finish unit test for left icon
* Remove unneeded check
* Don't bother adding stray props to E2EIcon for data-testid
* Upate snapshots
* Add support for Module API 1.3.0
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Add missing import
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Iterate
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Iterate
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Iterate
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Fix import
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Iterate
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Bump module API
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Update module API and remove jest stub
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Fix test mocks
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Improve coverage
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* types
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Coverage
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Coverage
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
---------
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Allow /upgraderoom command without developer mode enabled
This will make the instructions for upgrading rooms for hydra a lot
more straightforward, so maybe let's do this at least while hydra
upgrades happen.
* Update test to match
* Unused imports
* Better handle for resizer for new room list that doesn't support collapsing.
* Add unit test
* Test the new guards/checks on resize
* Finish cleaning up mock resets
* [create-pull-request] automated change
* First pass of fixing tests
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Second pass of fixing tests
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
* Third pass of fixing tests
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
---------
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
* Move Element Call event types to a more appropriate file
To remove the potential for import cycles in src/models/Call.ts, which I was accidentally creating when I tried to reference data from the RoomListStore in the ElementCall class.
* Make sure ElementCall tests clean up the call object
* Upgrade Element Call to v0.14.1
* Delegate the sending of call notifications to Element Call
As of Element Call version 0.14.0, the widget is now capable of sending call notifications itself if we just request this with the sendNotificationType URL parameter. This makes Element Web's group call code a little bit more succinct.
* Fix createRoom test
* feat: add `PlayPauseButton` to storybook
* feat: add generic media body
* feat: add seekbar component
* chore: add ViewWrapper to help writing stories with vm
* refactor: move `formatBytes` from `formattingUtils` into shared component
* refactor: add `className` props to `Clock`
* feat: add new audio player component
* test(e2e): add screenshots for new shared components
* feat: add AudioPlayerViewModel
* feat: use new audio player in `MAudioBody`
* refactor: remove old audio player
* test(e2e): update existing tests
* refactor: remove unused `DurationClock`
* refactor: rename `SeekBar` into `LegacySeekBar`
* Update for compatibility with v12 rooms
Stop using powerLevelNorm and reading PL events manually.
To support https://github.com/matrix-org/matrix-js-sdk/pull/4937
* Add test for leave space dialog
* Don't compute stuff if we don't need it
* Use room.client
* Use getSafeUserId
* Remove client arg
* Use getJoinedMembers
and add doc
* Fix tests
* Fix more tests
* Fix other test
* Clarify comment
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
---------
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
* implement basic scrolling and keyboard navigation
* Update focus style and improve keyboard navigation
* lint
* Use avatar tootltip for the title rather than the whole button
It's more performant and feels less glitchy than the button tooltip moving around when you scroll.
* lint
* Add tooltip for invite buttons active state
As we have for other icon based buttons in the right panel/app
* Fix location of scrollToIndex and add useCallback
* Improve voiceover experience
- As well as stylng cells, set the tabIndex(roving)
- Natively focus the div with .focus() so screen reader actually moves over the cells
- improve labels and roles
* Fix jest tests
* Add aria index/counts and remove repeating "Open" string in label
* update snapshot
* Add the rest of the keyboard navigation and handle the case when the list looses focus.
* lint and update snapshot
* lint
* Only focus first/lastFocsed cell if focus.currentTarget is the overall list.
So it isn't erroneously called during onClick of an item.
* Put back overscan and fix formatting
* Extract ListView out of MemberList
* lint and fix e2e test
* Update screenshot
It looks like it is slightly better center aligned in the new list, as if maybe it was 1 px to high with the old one.
* Fix default overscan value and add ListView tests
* Just leave the avatar as it was
* We removed the tooltip that showed power level. Removing string.
* Use key rather than index to track focus.
* Remove overscan, fix typos, fix scrollToItem logic
* Use listbox role for member list and correct position/count values to account for the separator
* Fix inadvertant scrolling of the timeline when using pageUp/pageDown
* Always set the roving tab index regardless of whether we are actually focused.
Fixes the issue of not being able to shift+t
* Add aria-hidden to items within the option to avoid the SR calling it a group.
Also
* Make sure there is a roving tab set if the last one has been removed from the list.
* Update snapshot
* Add labs option for "share history on invite"
* Set `acceptSharedHistory` when joining a room
* set `shareEncryptedHistory` when sending an invite
* Update src/i18n/strings/en_EN.json
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
---------
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
* MatrixChat-test: clean up better in `afterEach`
Make the MatrixChat tests behave better by letting them finish their work in an
`act` in afterEach. Otherwise we can end up mounting new components during
cleanup, which run tasks in the background
* MatrixChat-test: clean up dispatcher test
This test was kicking off a dispatcher job which would then open a
UserDeviceSettings dialog once the test had finished. That would then throw
exceptions because some of the mock environment had been torn down.
We're just testing that it opens the right dialog, so better to intercept
`createDialog`.
Aso add an `act` to reduce warnings, and replace a `flushPromises` with a
`waitFor` to make the test more robust.
* Allow Element Call to send call notifications
Currently Element Web is responsible for sending the call notification event, but this is planned to be changed soon. As of the upcoming Element Call 0.14.0 release, it will request the capability to send call notifications itself, and we should auto-approve this capability.
* Add reaction capability missing from test
Element Call does in fact request this one.
* Work around jest bug that swallows console output
Hacky workaround for https://github.com/jestjs/jest/issues/15747
* Fix unit test
* Only write logs if there are some to write
* Another test fix
* Add title attribute for message preview
So that the full message is shown in a tooltip on hover.
* Fix test
* Update src/components/views/rooms/RoomListPanel/RoomListItemView.tsx
Co-authored-by: Florian Duros <florianduros@element.io>
---------
Co-authored-by: Florian Duros <florianduros@element.io>