* Refactor NotificationBadge to shared MVVM
* Added snapshot images
* Replace legacy NotificationBadge with adapter
* Fix Eslint
* Use regular NotificationBadge prop names
* Remove legacy NotificationBadge selectors
* Update TAC badge Playwright selectors
* Rename NotificationBadgeAdapter to NotificationBadge
Addresses review feedback: the component is the app-facing badge, not an
adapter, so name it NotificationBadge.
* Make NotificationBadgeView isClickable a required boolean
Addresses review feedback: there is no semantic difference between
`isClickable: false` and `isClickable: undefined` (both render the
non-interactive variant), so the field should be a plain boolean. The
view model always provides it.
* Drop redundant comparison guards in NotificationBadge view model setters
Addresses review feedback: Snapshot.merge already compares each field
with Object.is and only emits when something actually changed, so the
manual equality guards in each setter were redundant. Recompute the
snapshot unconditionally and let merge dedupe.
* Resolve notification badge labels inside NotificationBadgeView
Addresses review feedback: static UI labels belong in the view, not the
snapshot. The view now resolves the knock and unsent-message strings via
useI18n, and the snapshot exposes a showUnsentTooltip boolean instead of
a prebuilt tooltipLabel (and drops knockLabel entirely). Adds the
room|knock_sent and notifications|message_didnt_send keys to the
shared-components i18n catalogue so they resolve in tests and storybook.
* Remove unused translation because of shared components movement
* Fix typescript issue
* Fix lint issue
* Remove unused notification badge count setting
* Pass notification badge class names explicitly
* Exploration of a virtuoso-powered emoji picker
moved to shared components
Fable generated
* fix pnpm lock
* format & fix some lint issues
* wrong import
* fix lint warning
* Fix off-by-one
and remove manual overflow adjustment: let's leave the default unless
it turns out to be necessary. Emoji should not take that long to load.
* Convert to functional component
* WIP: change to one big virtuoso scroller
* Change to use virtuoso's own onRangeChanged
and santitise category data and how it's passed around
* Convert Tabs to functional component
and put the focusing behaviour back with it just keeping track of
refs by itself.
* Absorb two line config file into main component
* Actually add the config to the main file
* Convert emoji to functional
Also make selected always defined and use useCallback.
* QuickReactions to functional component
* Non-default exports & doc
* Search to functional component
* Well it seems to work just fine now
* Use ref prop
* fix lockfile AGAIN
* lint
* Remove default export
* Remove some mx_ classnames and fix the inputRef
to make the arrow keys in the search box work (well, work as much as
they ever did).
* Remove last of the mx_ id / classnames
(except the one in the test)
* Use useMemo to memoize
* No need to export props interface (I think?)
and fix comment now we don't do the mutation stuff anymore
* Fix test
* Fix axe violations & add screenshots
* Avoid comparing dom snapshots in test
* Allow more before or after, just compare order of the ones present in both.
* Switch existing usages to new emoji picker
and kill the old one with fire
* Unused stuff
* Remove i18n strings
* Fix some tests
* Update screenshots
* Fix test
by removing the last of the weird memoized-but-mutated data structure
* Move the string somewhere more sensible than 'a11y'
* i18n lint
* Give the emojis IDs so aria-activedescendant works
* Fix more tests
* Add a small wrapper emoji picker component
This lets us easily memoize the recent emojis when the emoji picker is opened.
Also it saves a bit of boilerplate.
* Remove old emojipicker css
* Typos
Co-authored-by: David Langley <davidl@element.io>
* Use compound constants
* Rethemendex
* Use catalog version for emojibase
* Add comments
* More comments
* Fix comment
* More comments
* more comments (and make them uniform)
* More comments
* Fix pnpm lock again
* Another comment
* Apply button types to new version
* Add comment
* Disable screenshot
as per comment
---------
Co-authored-by: Will Hunt <2072976+Half-Shot@users.noreply.github.com>
Co-authored-by: David Langley <davidl@element.io>
* Make apps/web/playwright comply with strict mode
Otherwise it sometimes fails to compile matrix-js-sdk as strict mode & noImplicitAny both impact how overloads are asserted
* Iterate
* Add new setting to store section state
* Store section state in device settings
* Wire up section header view model and new section functions
* Update room list vm tests
* Add e2e test on section state persistence
* Use more intuitive syntax for SectionExpansionState
* Formatting
* Fix chats section staying expanded
* Add CHAT section case in e2e test
* Add functionality to UIStore
- Make it possible to query if the window is currently being resized
- Emit WidthIncreased/WidthDecreased events
* Change resize behaviour of panel
So that the panel does not become smaller when the window is resized.
This is consistent with the old room-list design.
* Introduce a `CollapseHandler` object
This should be used by the collapse behaviours to collapse/expand the
panel. There's a good reason to not have the behaviours depend directly
on the react-resizable-panels API methods: We dont want the collapse/expand
calls to conflict with each other. See the comments in the code for more
information.
* Introduce a base class for collapse behaviour logic
Behaviours should extend this class to describe when the panel should
automatically collapse and expand.
* Add the window resize collapse behaviour
* Create a central file from which to export all behaviours
* Add a class to orchestrate the collapse behaviours
ResizerViewModel will only have a dependency on this class.
* Collapse panel on app start if necessary
For eg, if the app is started with a small window width, the panel should be
collapsed.
* Wire auto collapse code into the viewmodel
* Write jest tests
* Fix e2e tests
* Fix lint error
* Fix e2e test failures
* Expand the panel before taking screenshot
Fixes incorrect narrow screenshots in RTE.spec.ts and CIDER.spec.ts
* Make comments consistent
* Move tests from jest to vitest
* Fix lint errors
* Improve comment
* Remove variable
* Remove mock
* Fix comment formatting
* Add back Favourites and Low Priority filter into shared components
* Wireup RoomList.showSections and filters in room list vm
* Add e2e test for filters and showSection setting
* Adapt OAuth2 implementation to Matrix Spec v1.18
* Handle more cases of oidc->oauth
* Fix test
* Fix read back of oauth2 context
* Iterate
* Fix tests
* Discard changes to apps/web/playwright/e2e/settings/account-user-settings-tab.spec.ts
* Fix test
* Fix test
* Fix test
* Potential fix for pull request finding 'Unused variable, import, function or class'
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
* Iterate
* Iterate
* Fix test
---------
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
* Change `feature_group_calls` to default to true.
Change state to Beta
* Add `enableLegacyCallsVoip` (clarify: Audio settings relate to Legacy)
Change `element_call.use_exclusively` to just be the default of
`enableLegacyCallsVoip`.
Allow disabling in Legacy in the settings. (overwrite `use_exclusivly`
via `enableLegacyCallsVoip`)
Rename `Voice & Video` to `Legacy Voice & Video`
* improvements
- settings title update to only show legacy when appropriate
- hide menu all together if use_exclusivly is chosen
* simplify by removing the feature_group_calls flag
* smaller cleanup
* fix tests and cleanup
* clarify settings (disable) in config.md
* add back EC relevant settings in room settings dialog
* update screenshots (now default to EC enabled (not disabled)
-> show voice and video tab in room settings
* update screenshots
* always show option to control voice messages input
* lint
* fix test
* disable -> enabled And only have on mic dropdown
* update config.md
* Back to `disabled` (on by default/no config)
* remove element call hint from voice-video settings
* Update apps/web/src/i18n/strings/en_EN.json
Co-authored-by: Robin <robin@robin.town>
* Update apps/web/src/components/views/settings/tabs/user/VoiceUserSettingsTab.tsx
Co-authored-by: Robin <robin@robin.town>
* review
* cleanup element call url setting (its deprecated/not used anymore)
* clarify, that also jisti will be enabled/disabled by legacy settings
flag
* remove double section
* remove unn exassary element_call configurations
* Update en_EN.json
* Update VoiceUserSettingsTab.tsx
* Make tests use new defaults (enable element call)
* Default events power levels
* format
* review "Enable Legacy voice/video calls" label
* more radical usage of defaults in element_call config.json's
* Update config.json
* Update en_EN.json
* Update RoomSettingsDialog-test.tsx.snap
* Update useRoomCall.tsx
* fix imports
* Update request permission promp to latest designs:
https://www.figma.com/design/aOEkaJtaBmPy058V7uoqVr/Element-Call-Updates---2026?node-id=45-12591&t=7takL39icZwt9YjL-0
* Update config.json.d.ts
* fix usage of `Element` in i18n
* Update General-room-settings-tab-should-be-rendered-properly-1-linux.png
---------
Co-authored-by: Robin <robin@robin.town>
* Add new settings to enable/disable the sections
* Add `RoomList.showSections` settings to preference user settings
* Hide sections ui in room list header
- Hide the collapse/expand button and the *new section* entry in the
menu.
- Display the *start chat* button instead of the compose menu when the
only action available is to create a DM
* Hide sections ui in context menu of room item
* Listen to show section settings in room list item vm
* Listen to show sections setting in room list header vm
* Put all the rooms inside the chat section when sections are disabled
When the chat section is the only section, the room list is in "flat
list mode". Putting all the rooms inside the chat section.
The section filters (aka custom section, favourites etc) are not passed
to the skip list.
* Update preferences settings screenshot
* Add e2e test for RoomList.showSections toggle
* Hide "Chat moved" toast when a room is tagged when RoomList.showSections is disabled
* start voice call in pip
* Update jest.config.ts
* fix "join" button to use correct intent
* Add regression test for join button
* Update RoomHeader-test.tsx
* fmt
* Add playwright test
* Fix expected intent on "join" button press
* Add additional pip check to exising:
`should be able to join a ${callType} call in progress` test
* Update RoomHeader-test.tsx
* Device dehydration tests: use common util for recovery setup
We have a utility method for setting up the recovery key, so let's use it.
* Factor out shared method for creating encrypted rooms
* Playwright test for device dehydration
Add a playwright test to check that this stuff actually works.
* Factor out `verifyAfterLogin` as a separate function
* Playwright test for dehydrated devices with MAS
* Device dehydration tests: use common util for recovery setup
We have a utility method for setting up the recovery key, so let's use it.
* Factor out shared method for creating encrypted rooms
* Playwright test for device dehydration
Add a playwright test to check that this stuff actually works.
* refactor(room-list): migrate SpaceStore off the legacy room list store
SpaceStore.setActiveRoomInSpace iterated the legacy RoomListStore's
`orderedLists` in `TAG_ORDER`; switch it to the space-aware
RoomListStoreV3.getSortedRoomsInActiveSpace() accessor. This drops the
last non-UI dependency on the legacy store and on `TAG_ORDER` (exported
from LegacyRoomList, deleted next).
* feat(room-list)!: remove the legacy room list UI
Delete the old sublist-based room list and its components now that the
new RoomListPanel is the default. Removed: LegacyRoomList,
LegacyRoomListHeader, RoomSublist, ExtraTile, RoomTile (+ Subtitle/
CallSummary), RoomBreadcrumbs and RoomSearch, plus their styles and
tests.
LeftPanel collapses to the RoomListPanel-only path. The shared
`contextMenuBelow` helper is relocated into RoomResultContextMenus (its
only remaining consumer).
* feat(room-list)!: remove the legacy RoomListStore
The legacy sublist-based room list UI is gone, so the old
`stores/room-list` store (Algorithm, sorters, filters, layout store,
space
watcher) has no remaining consumers. Delete the directory and its tests.
MatrixChat.forgetRoom no longer calls the legacy `manualRoomUpdate`; the
new room list store removes the room on the `AfterForgetRoom` dispatch
that still fires. Drop the `mxRoomListStore`/`mxRoomListLayoutStore`
globals and the now-dead test imports.
* feat(room-list)!: remove the feature_new_room_list labs flag
The new room list is now the only room list, so remove the
feature_new_room_list labs flag and make its enabled behaviour
unconditional everywhere it was gated:
- LoggedInView: always use the resizable layout and
NEW_ROOM_LIST_MIN_WIDTH;
drop the collapsible/minimized legacy path.
- SpaceStore: People and Favourites are dropped from metaSpaceOrder (per
the
long-standing TODO on the removed accessor).
- MessagePreviewStore: stop appending thread replies to previews.
- Settings, SidebarUserSettingsTab, PreferencesUserSettingsTab,
QuickSettingsButton, SpacePanel, LandmarkNavigation: drop the flag
reads and
legacy branches.
Update the tests that toggled the flag; the People/Favourites meta space
tests covered behaviour that the flag (default on) already disabled.
* feat(room-list)!: remove the dead legacy left-panel resizer
LoggedInView still built the old `Resizer`/`CollapseDistributor` over an
`lp-resizer` ResizeHandle and persisted `mx_lhs_size`. That handle is no
longer rendered (the resizable layout is now driven by
LeftResizablePanelView + ResizerViewModel, which persists its own state
via RoomList.panelSize/RoomList.isPanelCollapsed), so the old resizer
was
inert dead code left over from the legacy room list.
Remove createResizer/loadResizer/loadResizerPreferences, the
_resizeContainer/resizeHandler refs, the ResizeHandle render, the
mx_lhs_size handling and NEW_ROOM_LIST_MIN_WIDTH, plus the unit tests
that
exercised the mocked resizer.
* feat(room-list)!: update i18n files
* refactor(room-list): remove the now-unused collapseLhs state
`collapseLhs` is write-only since the left panel no longer collapses: it
was last read by LoggedInView's `shouldUseMinimizedUI`, removed with the
feature_new_room_list flag. Drop it from MatrixChat's IState (and its
assignments), collapsing the hide/show_left_panel handlers to just the
`notifyLeftHandleResized()` call they still need, and from
LoggedInView's
IProps and the test props.
* fix(room-list): instantiate message previewers lazily
Removing the unused SettingsStore import from MessagePreviewStore (when
the
feature_new_room_list flag was dropped) changed module load order and
exposed a latent circular dependency: ReactionEventPreview imports
MessagePreviewStore, which eagerly did `new ReactionEventPreview()` at
module-eval — so importing ReactionEventPreview first (as its unit test
does) hit "ReactionEventPreview is not a constructor".
Construct the previewers lazily on first use (cached) instead of at
module
load, so nothing dereferences a mid-evaluation module. Fixes
ReactionEventPreview-test.
* test(room-list): remove `feature_new_room_list` labs flag in e2e tests
* chore: remove remaining `newRoomList` flag
* chore: cleanup theme files
* fix: restore the re-resizable TouchEvent polyfill
* chore: remove usage of breadcrumbs settings in BreadcrumbStore
* Revert "fix(room-list): instantiate message previewers lazily"
This reverts commit 4e6eedfff0449c68a96c0470a4eb425b5aec5512.
* chore: remove unused function in BreadCrumbStore
* test: remove unused fuction of BreadcrumStore in tests
* test: add tests for RoomResultContextMenu
* Modify LinkPreview to export shared atomics
* Implement MessageComposerUrlPreviewView
* Create UrlPreviewFetcher utility function
* Modify view models
* Implement in composer
* Support running tests in dom-less vitest environment
* Add a playwright test
* hide another one
* fmt
* cleanup
* test rte too
* fixup
* Add back docstring
* cleanup
* off by one
* remove description check
* Cleanup hacks
* Remove another hack
* cleanup
* one more
* fixup window here too
* whoops type
* Rename to be cleaeer
* Trim URLs first
* fix bug
* Pluralise the multi-session remove button and confirmation dialog
When several sessions are selected in Settings > Sessions, the bulk remove button and its confirmation dialog used the singular "Remove this device" string. The singular "this" misleadingly implied the current device would be removed. Use the existing count-aware settings|sessions|sign_out_n_sessions key, matching the other-sessions menu, so the label reads "Remove N sessions".
Fixes#33812
* Update device-management e2e test for the pluralised remove button
The multi-select remove button now reads "Remove N sessions" instead of "Remove this device", so update the Playwright assertion to match.
* Put "Cancel" before "Remove N sessions" in the bulk session action bar
In the "Other sessions" multi-select action bar, "Remove N sessions" was
rendered before "Cancel", which placed the destructive action on the left.
Swap the two buttons so "Cancel" is on the left and "Remove N sessions" on the
right, per review feedback on #33983.
* Fix more menu focus issue when focused with no hover.
* Use a js based solution for focus
* Return focus to the menu trigger when closing the menu with Escape
Keep the keyboard-focus marker set while a row/section-header menu is open
(focus is then in the portaled popover, outside the element). This keeps the
trigger revealed so the menu's own focus restoration lands on it when closed
with Escape, instead of dropping to <body>.
* test: cover keyboard-focus reveal of the room list hover menus
Adds unit tests that focus a room row / section header via the keyboard
(:focus-visible on mount) and assert the hover menu is revealed, then cleared
when focus leaves. Brings diff coverage of the focus handlers to 100%.
* Forward the scroller element and scroll handle through VirtualizedList
The room list needs two things the generic list did not expose: the underlying
scroll container (to observe which items are genuinely visible) and the imperative
scroll handle (to scroll an item into view). Forward an optional scrollerRef from
useVirtualizedList and pass scrollHandleRef through FlatVirtualizedList, mirroring
what GroupedVirtualizedList already exposes. Both are additive and optional, so other
consumers are unaffected.
Signed-off-by: David Langley <langley.dave@gmail.com>
* Add an unread-activity toast to the room list
Show a clickable "You have unread activity" pill when there are unread rooms
scrolled below the visible fold, including unreads hidden inside collapsed sections
whose header is below the fold. Clicking it scrolls the next such unread into view.
The visible fold is tracked with an IntersectionObserver over the rendered item
elements, so the toast appears as soon as a room crosses the fold rather than only
once it leaves Virtuoso's overscan buffer. The toast click is wired through an
imperative scroll handle the view registers with the view model.
Signed-off-by: David Langley <langley.dave@gmail.com>
* Change toast to target notifications only, not unread activity.
* Fix formatting and refresh Toast snapshots for compound-web 9.7.0
- Apply oxfmt to the room list view model and virtualized view.
- Refresh the RoomListToast/RoomListView story snapshots: compound-web
9.7.0 moves the typography classes onto the toast .content element and
rebuilds the Toast CSS module hashes.
- Add the missing UnreadActivityToast render snapshot baseline.
* Add e2e tests for the room list unread activity toast
Cover the unread-activity toast end to end:
- it appears for a notifying room scrolled below the fold and clicking it
scrolls that room into view (then the toast clears);
- a room with only an unread-activity dot (no notification count) does not
raise it;
- a collapsed section hiding a notifying room raises it, and clicking
scrolls the section header into view.
* Add visual snapshot baselines for the unread-activity toast stories
* Converge room-list toast codepaths into a single state-driven toast
Reviewer feedback: the unread-activity toast and the transient event toasts
(section_created / chat_moved) should share one mechanism, with toast
lifecycle and precedence owned by the view model rather than split across a
separate snapshot flag and a view-level ternary.
- RoomListViewModel now reconciles the transient event toast and the derived
unread-activity state into a single snapshot.toast via recomputeToast(); the
event toast still takes precedence and auto-dismisses, and the unread toast
reappears once it clears. Drops hasUnreadActivityBelow from the snapshot.
- RoomListView renders a single RoomListToast driven by snapshot.toast; the
ToastType union gains 'unread_activity'. The standalone UnreadActivityToast
component is folded into RoomListToast (clickable arrow-down variant).
- Adds VM tests for the unread-activity toast and the event/unread precedence.
* Pre-bundle the room-list dnd-kit + virtuoso graph in vitest browser mode
The room-list suites (RoomListView, VirtualizedRoomListView,
RoomListItemMoreOptionsMenu) import a heavy @dnd-kit + react-virtuoso graph.
Only @dnd-kit/abstract was pinned in optimizeDeps.include; @dnd-kit/dom,
@dnd-kit/react, @dnd-kit/abstract/modifiers and react-virtuoso were left to
runtime discovery. Under CI load the browser-mode dep optimizer can discover
them late, re-bundle and reload the page, which fails the in-flight
setupTests.ts import for those suites. Pinning the whole graph forces it into
the initial optimize pass so no re-run happens while tests load.
---------
Signed-off-by: David Langley <langley.dave@gmail.com>
* feat(rls): centralize room-list section ordering via getOrderedSections
Introduce a single source of truth for the ordered list of section
tags (defaults + custom) in section.ts. RoomListStoreV3 no longer
hard-codes the default tag order — it asks section.ts.
* feat(vm): add section reorder logic to RoomListStoreV3 and view model
* refactor(sc): extract RoomListSectionHeaderContent from RoomListSectionHeaderView
* feat(sc): add drag-and-drop reordering for room-list sections
* test(sc): update existing tests
* test: add new tests
* test(sc): add snapshot test for overlay
* test(e2e): add playright test for dnd of sections
* feat: tweak opacity
* fix: section detection when dragged
* feat: use relative position in section order
* chore: move style to room list section header view
* test: add e2e test for moving section before another
* feat: make favourite and low priority no draggable
* test: remove deprecated e2e test
* fix: type correctly dnd provider and hooks
* fix: use String instead of casting to string
* fix: wrong a11y attributes on section header
* test: fix keyboard navigation e2e tests
* feat: use custom a11y announcement for dnd
* fix: add aria-hidden to the overlay
* chore: remove duplicated code in a11Y announcement
* fix: increase keyboard drag offset
* fix: tests
* fix: virtuoso computed item key
* fix: aria-expanded double annoncement why dragging
* fix: re-add screen reader instructions
* chore: remove unused import
* fix: reduce keyboard drag offset
* fix: improve text readback on unread section
* feat: use a custom a11y plugin instead of buitin a11y plugin
* chore: formatting
* test: fix incorrect tests
* chore: use randomUUID
* fix: try to make test working
* fix: put back mock
* fix: circular import
* Revert "fix: circular import"
This reverts commit 6c69313ade9ed2ab17a4622c692b435fbdb94ad2.
* chore: add @dnd-kit/abstract to optimizeDeps.include
* test: fix e2e tests
* fix: disable interaction with section when dragging
* fix: be more explicit if the section will be dropped before or after
* fix: add info that space is dropping too
* fix: scroll to dropped section
* test: fix virtualized room list test
* chore: update lang
* chore: fix dead code analyze
* test: add provider section story
* fix: lang
* fix: again lang...
* fix: improve voice over on chrome
* test: upate snapshot
* fix: add readback when a section is over a non droppable element
* Use real interface type for SynapseConfig
* Reconfigure for Synapse retention config
* Add beforeEach
* fix import
* lint lint
* fix number type
* fix
* cleanup
* formatted
This rejectToast was added erroneously: as the comment above states,
there should be no toast left after we verify (apart from our old
friend the notifications nag toast). This was probably flaking because
it was racing to reject the toast before it vanished.
* First pass at new retention
* Add more test cases
* fixup
* Fix TODO
* Disable retention explicitly from the start
* fixup
* Just apply retention as-is
* Fixup
* fix: hide section separator in context menu when there is no section
* fix: truncate long section name
* feat: add remove from section entry to room list item context menu
* test: update tests and stories
* test: add new test
* test: use same mocks
* test: add e2e test for "Remove from section"