mirror of
https://github.com/element-hq/element-web
synced 2024-11-28 04:21:57 +03:00
switch to 3-digit formatting for counts
This commit is contained in:
parent
91dd029483
commit
ab3c1509c5
1 changed files with 3 additions and 2 deletions
|
@ -25,6 +25,7 @@ var dis = require('matrix-react-sdk/lib/dispatcher');
|
|||
var Unread = require('matrix-react-sdk/lib/Unread');
|
||||
var MatrixClientPeg = require('matrix-react-sdk/lib/MatrixClientPeg');
|
||||
var RoomNotifs = require('matrix-react-sdk/lib/RoomNotifs');
|
||||
var FormattingUtils = require('matrix-react-sdk/lib/utils/FormattingUtils');
|
||||
|
||||
// turn this on for drop & drag console debugging galore
|
||||
var debug = false;
|
||||
|
@ -389,7 +390,7 @@ var RoomSubList = React.createClass({
|
|||
|
||||
var badge;
|
||||
if (subListNotifCount > 0) {
|
||||
badge = <div className={badgeClasses}>{subListNotifCount > 99 ? "99+" : subListNotifCount}</div>;
|
||||
badge = <div className={badgeClasses}>{ FormattingUtils.formatCount(subListNotifCount) }</div>;
|
||||
}
|
||||
|
||||
// When collapsed, allow a long hover on the header to show user
|
||||
|
@ -436,7 +437,7 @@ var RoomSubList = React.createClass({
|
|||
var overflowNotifCount = overflowNotifications[0];
|
||||
var overflowNotifHighlight = overflowNotifications[1];
|
||||
if (overflowNotifCount && !this.props.collapsed) {
|
||||
content = overflowNotifCount;
|
||||
content = FormattingUtils.formatCount(overflowNotifCount);
|
||||
}
|
||||
|
||||
var badgeClasses = classNames({
|
||||
|
|
Loading…
Reference in a new issue