mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-13 17:57:21 +00:00
Merge "Use words for describing notification counts in HTML text node"
This commit is contained in:
commit
705dd1d9d4
11
Hooks.php
11
Hooks.php
|
@ -921,8 +921,11 @@ class EchoHooks {
|
||||||
$sk->getOutput()->addJsConfigVars( 'wgEchoShowSpecialPageInvitation', true );
|
$sk->getOutput()->addJsConfigVars( 'wgEchoShowSpecialPageInvitation', true );
|
||||||
}
|
}
|
||||||
|
|
||||||
$msgText = EchoNotificationController::formatNotificationCount( $msgCount );
|
$msgFormattedCount = EchoNotificationController::formatNotificationCount( $msgCount );
|
||||||
$alertText = EchoNotificationController::formatNotificationCount( $alertCount );
|
$alertFormattedCount = EchoNotificationController::formatNotificationCount( $alertCount );
|
||||||
|
|
||||||
|
$msgText = wfMessage( 'echo-notification-notice', $msgCount );
|
||||||
|
$alertText = wfMessage( 'echo-notification-alert', $alertCount );
|
||||||
|
|
||||||
$url = SpecialPage::getTitleFor( 'Notifications' )->getLocalURL();
|
$url = SpecialPage::getTitleFor( 'Notifications' )->getLocalURL();
|
||||||
|
|
||||||
|
@ -971,7 +974,7 @@ class EchoHooks {
|
||||||
'class' => $alertLinkClasses,
|
'class' => $alertLinkClasses,
|
||||||
'data' => [
|
'data' => [
|
||||||
'counter-num' => $alertCount,
|
'counter-num' => $alertCount,
|
||||||
'counter-text' => $alertText,
|
'counter-text' => $alertFormattedCount,
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -986,7 +989,7 @@ class EchoHooks {
|
||||||
'class' => $msgLinkClasses,
|
'class' => $msgLinkClasses,
|
||||||
'data' => [
|
'data' => [
|
||||||
'counter-num' => $msgCount,
|
'counter-num' => $msgCount,
|
||||||
'counter-text' => $msgText,
|
'counter-text' => $msgFormattedCount,
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -9,14 +9,14 @@ Feature: Testing notification types
|
||||||
Given another user mentions me
|
Given another user mentions me
|
||||||
When I refresh the page
|
When I refresh the page
|
||||||
Then the alert badge is showing unseen notifications
|
Then the alert badge is showing unseen notifications
|
||||||
And the alert badge value is "1"
|
And the alert badge value is "Alert (1)"
|
||||||
|
|
||||||
@skip
|
@skip
|
||||||
Scenario: Someone writes on my talk page
|
Scenario: Someone writes on my talk page
|
||||||
Given another user writes on my talk page
|
Given another user writes on my talk page
|
||||||
When I refresh the page
|
When I refresh the page
|
||||||
Then the alert badge is showing unseen notifications
|
Then the alert badge is showing unseen notifications
|
||||||
And the alert badge value is "1"
|
And the alert badge value is "Alert (1)"
|
||||||
When I click the alert badge
|
When I click the alert badge
|
||||||
And I see the alert popup
|
And I see the alert popup
|
||||||
Then there are "1" unread notifications in the alert popup
|
Then there are "1" unread notifications in the alert popup
|
||||||
|
|
Loading…
Reference in a new issue