Commit graph

124 commits

Author SHA1 Message Date
jenkins-bot e28a912c3b Merge "Add 'mark as read' as secondary action to unread notifications" 2016-01-26 16:37:11 +00:00
jenkins-bot 73623d88b0 Merge "Truncate notification action button text" 2016-01-25 20:13:38 +00:00
Moriel Schottlender df3417e49c Fix table layout width for bundled notifications
Bug: T124023
Change-Id: I9b49ce5f066d93a6572c2dc5a859284a4ab182d4
2016-01-21 17:04:58 -08:00
Moriel Schottlender 79ac8be7fd Truncate notification action button text
Bug: T123657
Change-Id: I995c3383e7b465849773e4deaaa0d4a14524f6ac
2016-01-21 13:18:28 -08:00
Moriel Schottlender 5c67c9110f Add 'mark as read' as secondary action to unread notifications
Bug: T121935
Change-Id: I0dda7335ba00492c5dc5a6f0e9f2faea1da612bc
2016-01-21 11:34:27 -08:00
Roan Kattouw aa899d63d6 Set text color on header directly, not on <a>
The rules setting the text color on the <a> with
various strong specificity overrides were unnecessary.
Instead, simply set the text color on -header.
This also makes the text color apply if there is no
primary link, because there is no <a> in that case.

Bug: T123756
Change-Id: I02c7d28438678968fa64a59beeac3d8d26cb0702
2016-01-18 18:26:13 -08:00
Justin Du 7b5cf41e37 Adjust layout for new notification panel designs
Bug: T122646
Change-Id: I6cb6d121eb7e32737b1d73743061e1435e869c93
2016-01-18 18:00:14 -08:00
jenkins-bot 8e808fed77 Merge "Organize items in bundles with CSS table layout" 2016-01-19 01:04:11 +00:00
Moriel Schottlender 3472070b2b Organize items in bundles with CSS table layout
This will make the "flat" positioning of the bundle items a lot
more consistent and organized.

Bug: T121933
Bug: T123762
Change-Id: I472fcc89e540f1a886168069c547c6dc7e5ce613
2016-01-18 16:59:29 -08:00
Justin Du e02c06a46f Don't blur talk icon echo notifications
Keep padding around the icon at 0.5em on the left and 1em
on the right for now; we'll change this soon to make the
icon centered.

Bug: T123656
Change-Id: I8c04daee460dd72e2358c3aa315110e05a9a5312
2016-01-18 16:14:18 -08:00
Roan Kattouw d280df9a5b Fix content text alignment in GroupItemWidget
And add comments explaining what's going on.

Change-Id: I78700493e0eec922f1a9e95f397f0bf994a7cdde
2016-01-18 15:50:40 -08:00
Roan Kattouw ba61177e8a Follow-up 27092b7ae: add missing .prototype
Change-Id: Ie176bb98864f1ae755f0086eb1a55180a6b1635f
2016-01-18 15:37:05 -08:00
jenkins-bot c826294f30 Merge "Hide 'mark as read' for foreign NotificationGroupItem bundles" 2016-01-18 23:23:19 +00:00
Moriel Schottlender 27092b7ae9 Hide 'mark as read' for foreign NotificationGroupItem bundles
As a product decision it was decided that foreign notifications
cannot be 'mark all read' for their internal items.

Bug: T121930
Change-Id: I79292401b69adc4fad601192009296e02e8410b5
2016-01-18 15:17:57 -08:00
Roan Kattouw 76c550e018 ActionMenuPopupWidget: Close correctly when button is clicked
Bug: T123754
Change-Id: Ie0d97b820cd53c0cb09f6f998d49dc23d443d849
2016-01-18 15:01:17 -08:00
Roan Kattouw b80af26409 Set opacity:0.8; on the buttons in the footer of the notification popup too
Bug: T119378
Change-Id: I061d06dc13886618434b7022fc84f59feeaa426e
2016-01-18 14:28:19 -08:00
jenkins-bot a5e2466db4 Merge "Avoid pure black icons in Notification Panel" 2016-01-18 22:08:16 +00:00
Moriel Schottlender 902aec4a38 Mark bundles as read except when it is automatic
Make sure bundles can be marked as read by marking their sub-items
as read in the UI and also in the API.

However, for automatic 'mark as read' action (like the one that happens
when the model is "markReadWhenSeen") make sure to not mark-as-read
the bundles automatically.

Bug: T121930
Change-Id: I9d6bf6904fa3ca6559370e58853d29069f55af9e
2016-01-18 12:07:20 -08:00
jenkins-bot 51246dc130 Merge "Use 'next' as the default icon for secondary actions" 2016-01-15 20:47:10 +00:00
Roan Kattouw c345bef598 Add icon to "View changes" secondary links
Bug: T121736
Change-Id: I7dda877c26c99392c17702265380f4ea2a6e8049
2016-01-14 22:53:51 -08:00
Roan Kattouw 90c7055439 Use 'next' as the default icon for secondary actions
This ensures we always render an icon, even if there isn't one defined.

Bug: T121957
Change-Id: Iefd3c8778ed8aecb7f8caebeaed98121186602e2
2016-01-14 18:00:01 -08:00
haritha28 ddc3280c9d Avoid pure black icons in Notification Panel
The pure black icons which drew too much
attention when they are next to a lighter
text is changed by controlling the opacity
of the icons.

Bug: T119378
Change-Id: I2e6c8d47187621607a915e49cfe5380c744efe56
2016-01-14 18:53:28 +05:30
Stephane Bisson 60ddc76880 Update page-linked notification text
Bug: T121812
Change-Id: Ie875f105230c8364291a918b869b9c26dbdf1e83
2016-01-12 10:11:31 -08:00
jenkins-bot 99222dc95d Merge "Resized notification panel footer to be the same size as header" 2016-01-12 01:21:44 +00:00
jenkins-bot db9b8fe037 Merge "Log cross-wiki & bundle items impressions and add their source wiki" 2016-01-12 01:19:20 +00:00
Moriel Schottlender d123364035 Log cross-wiki & bundle items impressions and add their source wiki
Bug: T120158
Change-Id: Ibcd1923aaff4e1fd6fb1f54eefbc010122caa398
2016-01-11 17:12:38 -08:00
jenkins-bot edb74b9c63 Merge "Log the expand action of a notification group item" 2016-01-11 22:04:12 +00:00
jenkins-bot ec5107ece9 Merge "Expand group item on click" 2016-01-11 22:00:57 +00:00
mhutti1 033cba15c6 Resized notification panel footer to be the same size as header
Changed footer buttons height to match the headers height.

Bug: T119375
Change-Id: If215f109b74f2a645615fd89b7cbde6b2e6566d3
2015-12-28 13:24:34 +01:00
jenkins-bot 97f64ee855 Merge "Display readable API error message" 2015-12-23 20:18:34 +00:00
Moriel Schottlender 0d8bd17dd9 Log the expand action of a notification group item
Bug: T121945
Change-Id: I171d3e99a5529172177c9ddb9f17429609180321
2015-12-23 11:36:29 -08:00
Moriel Schottlender c387ac2a63 Add space between notification item buttons
Bug: T121955
Change-Id: Ica5123193ee6fc5252e27cdf3214072c6b9c3624
2015-12-23 09:32:22 -08:00
Moriel Schottlender 4b7520af90 Display readable API error message
If an error has occurred while fetching from the API, the
placeholder item should display the API error information.

If the error is specifically a login issue, a specific
error message is displayed.

Also, adjusted the mw.echo.ui.PlaceholderItemWidget to
accept a clickable link; when valid (currently only with
login error) the link is applied so the user can click
the notification and be taken to the login page.
For general notices (like API error or a general 'no
notifications found' message) the link does nothing.

Bug: T121923
Change-Id: I89a43c7c0eb2cf8e63d03704536e0938ab57dd4d
2015-12-22 10:34:01 -08:00
Matthias Mullie 089d922ac7 Use UTC timestamps in flyout
We already output unix timestamp both in user preference timezone as well as
utc, but we only had the user timezone version for TS_MW format.
While we could change the frontend to use the unix timestamp format, I don't see
any reason not to also include the MW format in utc. Frontend can now easily use
that.

Also fixed creation of the moment object. The timestamp was created as UTC, but
the way it got there was wrong: it expects the timezone offset (Z) to be
included in the timestamp, which is not the case (so it just ended up at +0:00,
which was fine, but confusing). I removed the 'Z' and forced it to be
interpreted as utc.

Bug: T121813
Change-Id: I09403615a1ffbde5dd69af9914afdbdd86cbfe4d
2015-12-22 17:07:31 +01:00
Moriel Schottlender 57a746f45f Expand group item on click
Have the group item expand itself not only when clicking the literal
'expand' button, but also when we click the entire item itself, as
if to open the notification item.

Renamed the expanding method so it is not specific for the button
event alone; also renamed the 'toggleExpand' to 'toggleExpanded',
as it toggles the inner 'expanded' state withot the API request
expansion process.

Bug: T121929
Change-Id: Iac23e06d1c17be4e1c5f63663fb0f81261f50070
2015-12-21 08:49:46 -08:00
Roan Kattouw 88d6f01c33 Make notification body text lighter
Use #888 instead of #666 to match secondary link text
(which is #000 with 50% opacity), both in the flyout and
on the special page.

Bonus: use LESS variables for these colors.

Change-Id: Ifc1182a001e9b25f6ff7c213b6fcde3dc2f0acd2
2015-12-18 13:13:22 -08:00
Moriel Schottlender a4659baec5 Add OOUI widgets for cross-wiki bundled notifications
* Add the ability to use bundled expandable
  notification groups
* Display bundled cross-wiki notifications following
  the design

Bug: T115419
Bug: T115423
Bug: T115422
Change-Id: I8c3eba6d627c3f06d51d74fc9774e3fc2d02915d
2015-12-14 17:22:34 -08:00
Moriel Schottlender 7d419bd128 Add a global overlay to Echo
This is preparing for nested popups inside the master popup.

Change-Id: I3bb86acd1bf841d5b27018565f5aa8f4a3295d9d
2015-11-23 18:47:57 +00:00
Moriel Schottlender 4bbaf77c2a Change the naming of 'notification option' to 'notification item' widgets
This is in preparation of adding more item models and widget types,
and in preparation of switching the notification widget away from being
a select widget.

Change-Id: I518fb3d80f4f67d677c21ca5593638269acfa544
2015-11-19 16:52:04 -08:00
jenkins-bot b46fcf57b3 Merge "Separate skin specific styles and improve Monobook appearance" 2015-11-11 02:18:59 +00:00
Ed Sanders 219b3d8b28 Separate skin specific styles and improve Monobook appearance
Bug: T112290
Change-Id: I1e73c92c69cf6df7c4d08b27a392f9c9bc19446f
2015-11-10 17:57:44 -08:00
Moriel Schottlender 02530f19e1 Implement SortedList in Echo notifications
This is especially important for combined notifications and
notification lists from different sources; the model list should
be sorted to reflect items by timestamp and unread status.

Note: The dm.List and dm.SortedList now mirror the structures
OO.EmitterList and OO.SortedEmitterList that are awaiting to be
added for oojs in Ib94e4e4a49 and  I3fd569691549 respectively.
Once those are available, the dm.List and dm.SortedList can
be removed, and the model can mixin OO.SortedEmitterList instead.

Change-Id: I97e1ecbe5dccc478be527a94f037500f78f74b14
2015-11-06 11:01:10 -08:00
Moriel Schottlender 44c2afbfee Initialize notifications model outside of the widget
Change-Id: I19c239326b04eaa07b62e0b06f181c86ff0a0ef8
2015-11-06 10:49:11 -08:00
jenkins-bot 188310641a Merge "Add an APIHandler to Echo notifications" 2015-11-05 19:57:43 +00:00
Moriel Schottlender 61f75f4c1e Make 'x' button in notifications bigger
Bug: T112217
Change-Id: Id645a14406accb006736df038fab667cdd9aabd1
2015-11-05 19:44:24 +00:00
Moriel Schottlender 466858bbe8 Add an APIHandler to Echo notifications
This simplifies the operation of the API a bit, but more importantly
this will let us create a demo where we can manipulate the API result
and test various new notification formats while the work on the
backend API responses is ongoing, and also will allow us to have a
constant test for all notifications types, including backwards
compatibility.

Change-Id: I6081329a287cda4f5f1f1604ace5d04ff8d9fe3d
2015-11-05 10:50:03 -08:00
jenkins-bot 14a5bc371d Merge "Add browser test for notifications in Echo" 2015-10-13 17:29:02 +00:00
jenkins-bot 8feb8212ce Merge "Override footer buttons hover color in Modern" 2015-10-09 06:29:22 +00:00
Moriel Schottlender 9f1bedda1c Override footer buttons hover color in Modern
In Modern, the hover color for links in the #p-personal bar is
white, which is unhelpful for the buttons in the popup. Override
that style for hover.

Bug: T114080
Change-Id: I8b739f2a46c3eb3ce9f61e92b5025751047a451d
2015-10-08 16:28:30 -07:00
Roan Kattouw 877e621a6a Fix various bugs in mw.echo.Logger and its callers
* Fix typo that caused logInteraction() to never do anything
* Fix incorrect context parameter passed by NotificationBadgeWidget
* Consistently use mw.Echo.Logger.static.context.* constants for the
  context parameter everywhere

Bug: T114833
Change-Id: I140e4222169ad9e78c6bf016d9765828513adcbb
2015-10-08 15:20:31 -07:00