Matthew Hodgson
89d05ac952
bring back 1.2M style badge counts rather than 99+
2020-09-10 13:51:34 +01:00
Michael Telatynski
9ba33c7f80
Fix eslint ts override tsx matching and delint
2020-08-29 01:11:08 +01:00
J. Ryan Stinnett
ce226ab534
Replace Riot with Element in docs and comments
...
This only covers the simple cases of references to issues and repos. More
complex areas, such as deployment scripts, will be handled separately.
Part of https://github.com/vector-im/element-web/issues/14864
2020-08-03 18:33:36 +01:00
Travis Ralston
8e7b60b11e
Remove useless if statement
2020-07-24 14:07:37 -06:00
Travis Ralston
593b472e50
Ensure notification badges stop listening when they unmount
2020-07-24 14:02:43 -06:00
Travis Ralston
bdb136e24e
Clean up TODOs, comments, and imports in the new room list
...
Fixes https://github.com/vector-im/riot-web/issues/14412
2020-07-13 20:25:02 -06:00
Travis Ralston
47380306c2
Move and improve notification state handling
...
Previously we were creating a notification state whenever we needed one, which was leading to hundreds of listeners even on a small account. To ease the burden, and reduce the load of having to wake so many listeners, we now record a single listener for each tag ID and room combination.
This commit also introduces a number of utilities to make future notification work a bit of an easier transition, such as the `isX` and `hasX` getters on the new NotificationState abstract class. Similarly, "snapshots" have been added to reduce code duplication between different kinds of states checking for updates.
The ListNotificationState is now heavily tied into the store which offers it to help reuse the cache of room notification states.
Fixes https://github.com/vector-im/riot-web/issues/14370
2020-07-08 19:26:25 -06:00
Travis Ralston
b54635863f
Merge branch 'develop' into travis/room-list/notification-state
2020-07-02 13:26:16 -06:00
Michael Telatynski
a658612078
Add click-to-jump on badge in the room sublist header
...
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2020-07-02 19:48:06 +01:00
Travis Ralston
782a555e44
Make badges represent old list behaviour
...
Fixes https://github.com/vector-im/riot-web/issues/14160
2020-06-30 13:45:10 -06:00
Travis Ralston
393eaf84c3
Move notification states out of the NotificationBadge component
...
Fixes https://github.com/vector-im/riot-web/issues/14153
2020-06-30 13:34:44 -06:00
Travis Ralston
ee2c216c4d
Clean up TODO comments for new room list
...
All relevant TODOs should still be present, and reference an issue for easy finding.
2020-06-28 20:03:04 -06:00
Travis Ralston
c920cf784e
Create a StaticNotificationState for representative purposes
2020-06-25 16:35:54 +01:00
Travis Ralston
fc5ee64fce
Fix read receipt handling in the new room list
...
Fixes https://github.com/vector-im/riot-web/issues/14064
Fixes https://github.com/vector-im/riot-web/issues/14082
Turns out the event doesn't reference a room, so we need to use the accompanied room reference instead.
2020-06-22 15:12:30 -06:00
Travis Ralston
fb551781c2
Force DMs to always be red notifications
...
This also passes the tagId to the sublist so it doesn't have to rip it out of the `layout`. It doesn't get a layout until later anyways, which causes some null issues.
2020-06-22 14:52:17 -06:00
Travis Ralston
63ad14ae1e
Clean up imports
2020-06-22 10:35:55 -06:00
Travis Ralston
8201eed929
Encourage counts if the user has a mention (red state)
2020-06-22 10:26:37 -06:00
Travis Ralston
eeb408a081
Update badge logic for new setting and behaviour
...
For https://github.com/vector-im/riot-web/issues/14084
2020-06-22 10:26:19 -06:00
Travis Ralston
7191c01265
Fix crash when filtering new room list too fast
...
Fixes https://github.com/vector-im/riot-web/issues/14092
We were simply assuming we had a reference to a notification state, which might not be the case if we're between renders.
2020-06-18 15:52:55 -06:00
Travis Ralston
d1c2ecb6cc
Add some resource leak protection to new room list badges
...
Most of the leaks were because we never set `this.rooms` in the notification state, which meant we were constantly triggering the `diff.added` loop.
2020-06-10 16:04:27 -06:00
Travis Ralston
eefc40e0f8
Use IDestroyable instead of IDisposable
...
For consistency within our project
2020-06-09 08:08:47 -06:00
Travis Ralston
8632d56e97
dispose -> destroy
2020-06-09 08:05:35 -06:00
Travis Ralston
086b9101fa
Add sublist badge counts to new room list
...
Also add IDLE state to rooms
2020-06-08 13:42:18 -06:00