Until the user opens the popup the first time, everything should be
unseen, rather than nothing unseen.
Also, make the default 'everything unseen' if we forget their seen
time.
Change-Id: I99ff8d46d4fa2fab0db374ddff63727b18a68363
- Add a 'hasUnseen' data to the xwiki bundle so the badge can
consider its value when changing its color even without the
bundle being opened.
- Check and store seenTimes from all sources that the xwiki
has in a new JS object that the SeenTimeModel can store
Bug: T134855
Change-Id: Ifdcee88b4378cdc7acb4ae5c0cbc60b76339757e
Follows-up If6319a02. Making the cache static enables us to reuse
the in-process cache across multiple instances of the class.
Bug: T144534
Change-Id: I1a594830f13d56ab4e0e636a3cdb5e96379e990a
That adds an in-process cache so we don't have duplicate key lookups on
every request.
Bug: T144534
Change-Id: If6319a026c457a32bfde0e212c6193aa728cb208
This will make the mobile view show unseen state if any of the
badges have unseen state rather than not show it if one of the
badges was more recently seen than the other in desktop.
Bug: T141404
Change-Id: I27109ee6a24831d58767f9bd13ed58e54094aee1
Like count, it is available both grouped by section and ungrouped
(top-level).
Unlike count, the top-level still has both sections (but with the
string 'seenTime' at the root), and if groupbysection is used,
it will not also have top-level (since it would be redundant).
Example output at T139993
It will be false or omitted if there is no seen time, depending
on JSON format version (2+ is false).
Bug: T139993
Change-Id: I9f4f9df69203204b56002afa1be6ed2336c33898
So we're not abusing user preferences for the last seen time.
EchoSeenTime is a small wrapper around ObjectCache that handles the
fallback to user preferences during the transition.
All JavaScript code now needs to use mw.config.get('wgEchoSeenTime').
Bug: T95839
Change-Id: Ia45ba5e30eb4564250539d04d5886d2598ebd49a