164 Commits

Author SHA1 Message Date
David Langley
242dc5ceb9
0.0.2 release with room list (#31982) 2026-02-06 12:20:26 +00:00
Florian Duros
abdb307279
Publish shared components storybook (#31907)
* doc: add typedoc generation for shared component

* ci: add SC doc publish

* ci: push doc on changes on develop

* ci: fix working directory

* doc: add typedoc generation into storybook

* doc: build i18n files for storybook static sites

* ci: change workflow to deploy storybook

* chore: exclude non-ui tests from vitest visual tests

* chore: try to fix error in CI

* doc: fix broken link in README

* doc: add typedoc missing export plugin

Add https://github.com/Gerrit0/typedoc-plugin-missing-exports to avoid
to have to explicit export all the types which are not used outside SC

* doc: add mapping to external docs

* fix: remove shebang
2026-02-06 10:01:42 +00:00
ElementRobot
56d9a5d93e
[create-pull-request] automated change (#31981)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-02-06 09:05:31 +00:00
David Langley
6da1412de8
Migrate the room list view to shared components (#31921)
* Add NotificationDecoration component

Add the NotificationDecoration component to shared-components.
This is a leaf component that renders notification badges and indicators
for rooms/items including mentions, unread counts, call indicators, etc.

* Add RoomListItem component

Add the RoomListItem component to shared-components.
Includes context menu, hover menu, notification menu, and more options menu.

* Add RoomListPrimaryFilters component

Add filter chips component for filtering the room list by
unread, people, rooms, favourites, mentions, invites, and low priority.

* Update VirtualizedList component

Update VirtualizedList to support the room list virtualization requirements.

* Add RoomList component

Add RoomList component that renders a virtualized list of room items.
Includes story mocks for testing.

* Add RoomListView component

Add RoomListView component that composes RoomList with filters,
empty states, and loading skeleton.

* Export room-list components from shared-components

Add exports for RoomListView, RoomListItem, RoomListPrimaryFilters, and RoomList.
Include i18n strings for room list components.

* Add RoomListItemViewModel

Add view model for individual room list items.
Manages per-room subscriptions and updates only when specific room data changes.

* Add RoomListViewViewModel

Add view model for the room list view.
Manages room list state, filtering, keyboard navigation, and child view models.

* Integrate shared components into RoomListView

Update RoomListView to use the new ViewModels and shared components.
Includes i18n string updates for element-web.

* Remove old room list implementation

Remove old ViewModels, hooks, and view components that are now
replaced by the shared-components implementation.

* Update sliding-sync playwright test

Update test expectations for new room list implementation.

* Add figma links

* Move viewModels to the right folder

* Rename to RoomListEmptyStateView

* Update VirtualizedRoomListView naming

* Update screenshots and snapshots

* Move viewmodel tests to the right location and fix some imports

* lint

* Use unknown as an Opaque type rather than any. It discourages property access within shared components and can still be cast back in EW.

* Update screenshots for new shared component rendering params

* Make room order tests deterministic
2026-02-05 21:05:14 +00:00
renovate[bot]
6dba71a453
Update dependency @playwright/test to v1.58.1 (#31957)
* Update dependency @playwright/test to v1.58.1

* Update snapshots & screenshots

* Another screenshot

* Un-focus room tile and scroll it into view

possibly some change in what ends up focused after a popup disappears

* uncomment the screenshots

* Correct screenshot

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: David Baker <dbkr@users.noreply.github.com>
2026-02-05 16:41:48 +00:00
David Baker
1d7fd0b9d3
Add options for consistent screenshots (#31973)
* Add options for consistent screenshots

Attempt 2

* Update aaaaaaaal the snapshots

or the ones with text, anyway

* Add comment

* prettier
2026-02-05 11:21:44 +00:00
Florian Duros
7738be32ec
chore: allow 3px of difference in SC visual tests (#31972) 2026-02-04 16:56:08 +00:00
Zack
c647c8ee3d
Refactor Timeline Seperator (#31937)
* Refactor TimelineSeparator to shared-components package

  • New TimelineSeparator component in packages/shared-components/
  • Updated MessagePanel.tsx to import from shared-components

* Fix copyright text

* Timeline Unit Tests + Timeline Snapshot Tests

* Imported correct timeline seperator

* Update snapshots because of css update

* Apply suggestion from @florianduros

Co-authored-by: Florian Duros <florian.duros@ormaz.fr>

* Created className prop

* Removal of element x unused css

* Update snapshot because of Flex

* Update snapshots because of Flex

* Update css to correct values and compund name

* Added letter spacing to timelineseperator

* rremoval of letter spacing

* added align center to flex to apply correct css changes

* Update snapshots to reflect new css changes

* Update snapshots to reflect css changes

* Added letter-spacing to timeline seperator

* Update snapshots after css update

* update snapshots

---------

Co-authored-by: Florian Duros <florian.duros@ormaz.fr>
2026-02-04 13:25:36 +00:00
renovate[bot]
b9de284c39
Update npm non-major dependencies (#31960)
* Update npm non-major dependencies

* Fix type

* Katex comes with its own types now

Or possibly it always had them but they just put them in the package.json

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: David Baker <dbkr@users.noreply.github.com>
2026-02-04 11:21:16 +00:00
Florian Duros
877ab183d9
refactor: move Clock from class component to functional component (#31964) 2026-02-04 11:15:06 +00:00
ElementRobot
ae013686f5
[create-pull-request] automated change (#31968)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-02-04 06:43:01 +00:00
renovate[bot]
2039a2a5bb
Update storybook to v10.2.3 (#31956)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-02-03 21:47:47 +00:00
renovate[bot]
679e8442a0
Update dependency eslint-plugin-storybook to v10.2.3 (#31955)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-02-03 18:13:00 +00:00
rbondesson
a1be203683
Move EventTileBubble to shared components (#31911)
* Move EventTileBubble to shared components as is

* Added documentation and updated stories and unit tests

* Move 'global' element web css to _common.pcss

* Adding playwright snapshots

* Updated comments

* Added legacy mx_MessageTimestamp class and updated snapshots

* Regenerate snapshots with correct hash

* Changes to css and removed timestamp from properties after review.

* Update screenshot for room-list and fix flaky CI playwright test.

* Blur the play button before matching screenshots

* Changed to button focused instead of blur for consistancy

* Stabilize play button appearance in CI (disabled due to decoding)

* Force play button appearance in CI (disabled due to decoding)

* Add comments on playwright test changes.
Change from React.RefObject<any> to Ref<HTMLDivElement> in EncryptionEvent.tsx

* Update playwright/e2e/composer/CIDER.spec.ts

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>

* Update playwright/e2e/composer/CIDER.spec.ts

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>

* Update playwright/e2e/crypto/toasts.spec.ts

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>

---------

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2026-02-03 14:37:57 +00:00
Richard van der Hoff
af55def428
Add badge for history visibiltity to room info panel (#31927)
* Add `HistoryVisibilityBadge` shared component

* Add `historyVisibility` to `RoomSummaryCardViewModel`

* Add a history visibility badge to the room info panel

* Allow roominfo panel badges to wrap

Now that we have an extra one, it's quite likely we'll have to spill onto more
lines.

* update screenshots

* Set icons in badges to be 16px

Having discussed this with the design team, the icons in badges should be 16px, not 13px,
at default font size settings.

* Add stories for all history visibility states

* fix incorrect use of useRoomState

* fix snapshots

* more snapshot updates

* Update screenshots
2026-02-03 12:50:00 +00:00
ElementRobot
0053bedc38
[create-pull-request] automated change (#31935)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-02-02 06:49:46 +00:00
rbondesson
25d24d478f
Refactor DecryptionFailureBody using MVVM and move to shared-components (#31829)
* Refactor DecryptionFailureBody to MVVM and moving it to shared components

* Added unit test for DecryptionFailureBodyViewModel

* Removing the dependency to matrix.js-sdk from the shared component

* Kepp class mx_EventTile_content for tile layout

* Required changes after rebase

* Updates after PR review requests

* Clean up unused translation tags in element-web

* Added missing unit tests to improve coverage

* Additional unit tests to improve test coverage

* Removing obsolete tests from the snap

* Only listen to verification state changes in the wrapper components and also limit the view model to only allow updates in verification state.

* Updates after review requests

* Updated and added missing playwright snapshots

* Bettter structure on view model

---------

Co-authored-by: Florian Duros <florianduros@element.io>
Co-authored-by: Zack <zazi21@student.bth.se>
2026-01-30 12:44:23 +00:00
Zack
62c7fe5408
Refactor ReactionsRowButtonTooltip to shared-components (#31866)
* Setting up structure for the init refactoring of ReactionsRowButtonTooltip

* implemented example to follow for refactoring to MVVM

* Refactoring of ReactionsRowButtonTooltipView

* updated reactionrowbutton to use our new viewmodel and removed unessecery comments

* Updated children from reactnode to propswithchildren

* removal of children on the vm have it as a props

* implemented constructor into reactionrowbutton to use vm to viewmodel

* Removal of old component

* Added ViewModel Tests for new viewmodel

* Fix issues after merging develop

* Updated import placement for eslint failure CI

* Add tests for ReactionsRowButton ViewModel integration and click handlers to pass coverage

* Added more tests to cover all conditions

* Pass MatrixClient as prop instead of using global; replace expect(true).toBe(true) with not.toThrow()

* Added new snapshot to reflect modifications on tests

* Update images to fit the CI tests

* Optimize reactions tooltip viewmodel updates

* Removal of module.css for reactionbuttontooltip, we dont need it since we dont use any css

* Fixed snapshots to show the tooltip by introducing a boolean to set open to true in Storybook.

* Update snapshots

---------

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-30 11:53:57 +00:00
ElementRobot
8cef5df140
[create-pull-request] automated change (#31918)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-01-30 06:40:43 +00:00
Michael Telatynski
e07e26cae5
Fix emoji verification responsive layout (#31899)
* Extract SasEmoji to shared-components

and improve responsive layout

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Add baseline screenshots

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update tests

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Fix e2e test

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Add SasEmoji snapshot test

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Add figma link

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Improve doc

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Add new dir to crypto-web-reviewers codeowners as per ask

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

---------

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-29 17:40:04 +00:00
ElementRobot
b31527261d
[create-pull-request] automated change (#31862)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-01-29 10:57:38 +00:00
Marc
8bb1cb5e63
MVVM WidgetContextMenu component to shared component (#31190)
* Create WidgetContextMenu component in shared-components

* Modify WidgetMenuContext call (apptile, extensioncard, widgetcard), test and stories

* Correctly use new widgetcontextmenu component

* WidgetContextMenuViewModel unit test

* Lint and add comments

* Finalize widgetcontextmenuviewmodel test

* fix lint errors

* Fix test error

* Update playwright screenshots

* add userWidget in widgetcontexstmenu props

* Fix some a11y issues on playwright

* fix linter error widget card

* Use new i18n way for share component widget context menu

* Add i18n context provider for widget context menu

* chore: lint and update snapshot widgetcontextmenu
2026-01-29 10:22:47 +00:00
renovate[bot]
e5f0ea79e5
Update playwright (#31895)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-27 16:48:33 +00:00
renovate[bot]
b908e8c7f2
Update dependency @vector-im/compound-design-tokens to v6.9.0 (#31896)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-27 16:23:34 +00:00
Florian Duros
a972340216
doc: update SC visual test doc (#31897) 2026-01-27 13:31:14 +00:00
Skye Elliot
d0c60e6ee4
Remove "history may be shared" banner. (#31881)
* Revert "Update algorithm for history visible banner. (#31577)"

This reverts commit ce9c66ba4c25f3de5ceca5d244591d8aa1183ce8.

* Revert "Update prop type & documentation for HistoryVisibleBanner and VM. (#31545)"

This reverts commit 4da149e56f5a593daf05ed9a84eea7da11d800e9.

* Revert "Prevent history visible banner from displaying in threads. (#31535)"

This reverts commit c7134e85324878f06da3936ccad09655876cad0d.

* Revert "Implement UI for history visibility acknowledgement. (#31156)"

This reverts commit cff9119324dced2ab570201d159ea0c8169344c2.
2026-01-27 11:28:33 +00:00
David Langley
d6f11d828b
Migrate ListView to shared components (#31860)
* Migrate ListView to shared components

* Add stories

* lint

* Update name of component

* Use compound spacing

* lint

* VirtualizedList

* Simplify story

* Add git diff check before uploading artifacts

* Fix git diff workaround for vis

* Ignore coverage report in .gitignore

Add coverage report to .gitignore

* Add screenshot test

* Fix package and lock files

* clear unneeded lock file changes

---------

Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-26 17:58:46 +00:00
Florian Duros
3f26b37cf8
doc: add doc how to publish a new version of shared components (#31882) 2026-01-26 15:47:24 +00:00
Florian Duros
28609f4e7a
Fix room list menu flashes when menu is closed (#31868)
* chore: update compound to `8.3.6`

* chore: update snapshots
2026-01-26 13:35:16 +00:00
Florian Duros
3f212537b6
chore: bump shared components to 0.0.1 (#31877) 2026-01-26 13:10:45 +00:00
Michael Telatynski
7459850f6a
Fix storybook language addon (#31880)
It was not working for languages like de_DE which were normalised to de in one codepath but not the other

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-26 12:44:57 +00:00
Florian Duros
3fc3653809
refactor: move vm hooks into view model folder (#31832) 2026-01-22 17:28:14 +00:00
renovate[bot]
51f5ec021a
Update dependency lodash to v4.17.23 [SECURITY] (#31852)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-22 15:31:16 +00:00
Michael Telatynski
35fca4d339
Switch shared-components from jest & test-runner to vitest (#31800)
* Remove babel

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Remove duplicated patch-package dep

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Switch to @fetch-mock/vitest

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update tests to import & call vitest functions

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update test-utils imports

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update unit test snapshots

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Switch from jest->vitest for unit tests

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update visual test screenshots

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Switch from test-runner->vitest for visual tests

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update README

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update CI for shared-components unit & visual tests

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update yarn.lock

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update README

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Fix storybook trying to import vitest

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Fix css modules leaking between storybook tests

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Tweak screenshot update script to accept args

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

---------

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-22 14:17:36 +00:00
Michael Telatynski
e0b3e013ab
Remove shared-components slow reporter to un-break CI
as we don't have a js-sdk dep in shared-components
2026-01-22 10:16:52 +00:00
R Midhun Suresh
d6d647f56d
Unread Sorting - Add option for sorting in OptionsMenuView (#31754)
* Add new sort option

* Support new sorting algorithm in vm

* Add option item for unread sorter

* Add tests
2026-01-22 09:56:47 +00:00
Michael Telatynski
2de53e306a
Tidy shared-components storybook (#31836)
* Fix compound.css - it is not pcss

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Improve types in shared-components storybook

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Update i18n:sort script and remove patch-package

---------

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-21 15:22:13 +00:00
renovate[bot]
6b48b022cb
Update dependency matrix-web-i18n to v3.6.0 (#31837)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-21 14:34:39 +00:00
renovate[bot]
ecb204a533
Update storybook to v10.2.0 (#31838)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-21 14:34:34 +00:00
Florian Duros
50d8fd2440
doc: add documentation how to write stories in shared components (#31831) 2026-01-21 13:31:52 +00:00
Florian Duros
bc6375d7ab
Add message preview toggle to room list header option (#31821)
* feat: add message preview action to room list header option

https://github.com/element-hq/element-web/issues/31214

* test: add e2e test
2026-01-21 10:43:35 +00:00
Michael Telatynski
819d361a91
Prepare for vitest in shared-components (#31820)
* Use typescript for vite config

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Switch shared-components to ESM

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Remove stale aliases

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Remove reference to element-web files from shared-components

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

* Remove spurious node polyfill

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>

---------

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2026-01-21 10:04:27 +00:00
Florian Duros
9edddce149
RoomList: move room list header to shared components (#31675)
* chore: ignore jest-sonar.xml in gitconfig

* chore: add missing rtl types to shared component

* chore: add `symbol` to `Disposables.trackListener`

* feat: add room list header view to shared components

* fix: change `Space Settings` to `Space settings`

* feat: add room list header view model

* chore: remove old room list header

* chore: update i18n

* test: fix Room-test

* test: update playwright screenshot

* fix: remove extra margin at the top of Sort title in room options

* test: fix room status bar test

* fix: change for correct copyright

* refactor: use `Disposables#track` instead of manually disposing the listener

* refactor: avoid to recompute all the snapshot of `RoomListHeaderViewModel`

* wip

* fix: make header buttons the same size than figma

* test: update shared component snapshots

* test: update shared component screenshots

* test: update EW screenshots
2026-01-21 09:06:01 +00:00
renovate[bot]
5783ee4cb8
Update npm non-major dependencies (#31810)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-20 17:54:52 +00:00
renovate[bot]
027047e0ae
Update dependency @vector-im/compound-design-tokens to v6.8.0 (#31812)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-20 15:21:33 +00:00
renovate[bot]
006ad8868d
Update dependency @element-hq/element-web-playwright-common to v2.2.4 (#31808)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-20 15:15:54 +00:00
ElementRobot
1c42173e5b
[create-pull-request] automated change (#31786)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-01-19 09:23:52 +00:00
Richard van der Hoff
52748d6d35
Minor corrections on shared-components/README.md (#31741)
* Minor corrections shared-components-README.md

a few minor edits and clarifications

* Wrap lines at 80 characters

Mostly, this means that diff comments on PRs work better.

* Update packages/shared-components/README.md

* Apply suggestion from @richvdh
2026-01-16 18:13:57 +00:00
Florian Duros
b9638695b7
Update compound to 8.3.5 (#31736)
* chore: update compound to `8.3.5`

* refactor: remove incorrect color in shared components

* test: update shared components snapshots

* test: update shared component screenshots

* test: update EW snapshots

* test: update EW screenshots

* test: update snapshot
2026-01-16 14:30:08 +00:00
ElementRobot
e2dad68169
[create-pull-request] automated change (#31753)
Co-authored-by: t3chguy <2403652+t3chguy@users.noreply.github.com>
2026-01-16 11:45:30 +00:00