Commit graph

2379 commits

Author SHA1 Message Date
jenkins-bot 0416f39e68 Merge "Expose more data through API" 2015-11-20 23:41:55 +00:00
jenkins-bot 7a68a05083 Merge "Prevent link color on hover for the body ("payload") as well as the header" 2015-11-20 23:39:37 +00:00
jenkins-bot acdcdb29f0 Merge "Remove styling for nonexistent mw-echo-title-heading class" 2015-11-20 23:38:58 +00:00
Translation updater bot 72f7e4977c Localisation updates from https://translatewiki.net.
Change-Id: Ic0b0500a67c53837b0d189ae3e8076e6f08dac63
2015-11-20 22:55:15 +01:00
Matthias Mullie 0ef4df8e15 Expose more data through API
Instead of relying on the frontend to render, this enables the frontend
to do it.

The API will now accept a new format: 'model', which is basically the
presentation model's data in json format.

Some of the render code is currently only in the backend (e.g. get icon
path from icon type) so other api formats will stay available. At some
point, however, we may be able to kill those.

Bug: T115418
Change-Id: Ibc3ad54c94d6ea9bf751f3927cf69e1d062f4780
2015-11-20 19:27:34 +00:00
jenkins-bot 6bb3738812 Merge "Change the naming of 'notification option' to 'notification item' widgets" 2015-11-20 00:58:16 +00:00
jenkins-bot 8db241e328 Merge "Add a NetworkHandler as a central API authority to Echo" 2015-11-20 00:55:01 +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
Kunal Mehta 8c49a812e1 Unstub $wgLang in BasicFormatter::getLanguage() too
Bug: T118542
Change-Id: Ic9f3c03a3f1d38f2ea420cf32dcd3bb33d6c3635
2015-11-19 16:34:13 -08:00
Moriel Schottlender 24a8bc23ef Add a NetworkHandler as a central API authority to Echo
This is in preparation for dealing with cross-wiki notifications
where we may need several types of operations to extract bundled
notifications from local and external APIs.

Also, renamed files:
* mw.echo.dm.AbstractAPIHandler -> mw.echo.dm.APIHandler
* mw.echo.dm.APIHandler -> mw.echo.dm.LocalAPIHandler
* All API-related handler files moved to their own folder
  for better organization.

Change-Id: Ib730c780ea52c93a6026c5d0b22012b6f39bb50d
2015-11-19 15:25:03 -08:00
Translation updater bot 85943737b3 Localisation updates from https://translatewiki.net.
Change-Id: I273cf2ae0270089a437579510819e03ec4d0979e
2015-11-19 21:35:25 +01:00
Kunal Mehta a00628b42a EventMapper::fetchByUserBundleHash(): Always return an array
It's basically impossible for DatabaseBase::select() to return false now
that ignoreErrors() is protected. So always return an array so callers
don't have to worry about false.

And remove a test that checked the result if DatabaseBase::select() did
return false.

Change-Id: I9ca8511585403d8c0ec262898ad4e61c2b038d51
2015-11-19 10:12:43 -08:00
Roan Kattouw c8d0115fd5 Prevent link color on hover for the body ("payload") as well as the header
Change-Id: Id221af75ed76122b03f741c184053e73bd2f4ee5
2015-11-18 20:10:40 -08:00
Roan Kattouw 8e46160210 Remove styling for nonexistent mw-echo-title-heading class
Change-Id: Ia1ce2889ec0e740d0fcc7d49809d5c64d24a696c
2015-11-18 20:07:53 -08:00
jenkins-bot 904e1e5a8c Merge "Presentation model for reverted" 2015-11-19 00:55:46 +00:00
Translation updater bot 08c3927cdf Localisation updates from https://translatewiki.net.
Change-Id: Ifa294aa5da19e1ca2aaae0e818bf673912f4a63b
2015-11-18 21:57:28 +01:00
jenkins-bot 9c40143cef Merge "Presentation model for email-user" 2015-11-18 18:42:00 +00:00
jenkins-bot 5100bba74f Merge "Extract getMessageWithAgent" 2015-11-18 17:53:03 +00:00
Stephane Bisson b3ab132ffd Extract getMessageWithAgent
`getMessageWithAgent` is used by `getHeaderMessage` is can
be reused by other presentation models who need the
agent in their body message.

Bug: T118059
Change-Id: I0cbccaeb8b6e60d03bc75bc85c74591619b4399a
2015-11-18 09:47:24 -08:00
Matthias Mullie a35bf21084 'Load more' check should be based on retrieved data, not what could render
Since EchoEventPresentationModel::canRender can reject notifications,
its result should no longer be used for infinite scroll.

Current code checks if the amount of to-be-rendered data exceeds what
we need to display, but if we reject some notifications that may no
longer be the case, even though there is more data still.

Change-Id: I3e5f8c2d1fc0c63db7b277324c96af043689ddce
2015-11-18 11:06:22 +01:00
Translation updater bot 643cf2a3a3 Localisation updates from https://translatewiki.net.
Change-Id: Ibe9631ed63c484aaa029a3b790488b1c8aa62a03
2015-11-17 21:51:23 +01:00
Kunal Mehta 609c941323 Remove "learn more" link from user-rights notification in flyout
The primary link already goes to the exact same target, so the
link is redundant.

Change-Id: I7c76bcb000c7b41f45b0df2cdaaebf0e9ca77404
2015-11-17 10:04:56 -08:00
Stephane Bisson 44149b6cbd Presentation model for email-user
Bug: T116843
Change-Id: I99e790d72c7c534665d1d86c38459c5d0e60b91b
2015-11-17 12:44:45 -05:00
Stephane Bisson 3fa832c6c7 Presentation model for reverted
Bug: T116843
Change-Id: Ide03220ad8ad621b5943e36d71e484a21bc8a65b
2015-11-17 10:19:15 -05:00
Kunal Mehta 8145cd1425 Remove old, now unused mention flyout messages
These are no longer used in the interface, 'notification-header-mention'
and 'notification-header-mention-nosection' are used instead.

Change-Id: I08ffe47cf7932637b77f43f6ec374272b5e3ca3e
2015-11-16 15:49:44 -08:00
Translation updater bot 18606871c0 Localisation updates from https://translatewiki.net.
Change-Id: Id3e226ad7f7de134a545dc4800da36574a273770
2015-11-16 22:14:43 +01:00
Kunal Mehta dbc83a0c0c Unstub $wgLang before passing it to DiscussionParser::getTextSnippet()
getTextSnippet() has a `Language` type hint that will fatal if $wgLang
is a StubUserLang object, so make sure we unstub it if nothing else
already has.

Bug: T118542
Change-Id: I847680074fbbf95bbe3b6002151d2a18c45ebe6e
2015-11-16 10:41:51 -08:00
Translation updater bot 236c9360be Localisation updates from https://translatewiki.net.
Change-Id: Id40c06a5b32ec54222bb4a7abed10848e77174bf
2015-11-15 22:17:01 +01:00
Translation updater bot a070d2ccae Localisation updates from https://translatewiki.net.
Change-Id: Ie6358999cbb818c35f097a9f8789568605e092a1
2015-11-14 22:16:20 +01:00
Translation updater bot 15a51cab93 Localisation updates from https://translatewiki.net.
Change-Id: I04629e1ffafe9ef9c987b4c285b32bd426a84fe6
2015-11-13 21:32:58 +01:00
jenkins-bot a548832580 Merge "Remove unncessary code from NotifUserTest" 2015-11-12 23:58:12 +00:00
jenkins-bot 72cb6202b0 Merge "EventPresentationModel: Add accessor for current user's username" 2015-11-12 23:58:10 +00:00
jenkins-bot 20579a711b Merge "Allow welcome notifications to have a primary link" 2015-11-12 23:53:08 +00:00
jenkins-bot b36847f95f Merge "Fix some phpdoc, add missing @throws" 2015-11-12 23:52:06 +00:00
jenkins-bot e1c29e8d24 Merge "Remove unused NotifUser::getFormattedNotificationCount()" 2015-11-12 23:51:07 +00:00
jenkins-bot 1428d9e797 Merge "Browser Tests: fix" 2015-11-12 23:38:09 +00:00
Stephane Bisson 10c4ed6f49 Browser Tests: fix
* extract notifications to components/notifications.rb
* wait for the flyout to be loaded before counting
  the unread notifications
* remove popup.feature because it is redudant with
  notifications.feature and too low-level
  for acceptance testing

Change-Id: If0b0286e8e98e379ae1d6d91db8084adda93b3f6
2015-11-12 15:17:07 -08:00
Kunal Mehta 40667ca7d4 EventPresentationModel: Add accessor for current user's username
Only to be used for GENDER purposes.

Bug: T118058
Change-Id: I5cf0563374ac1eaf934fecbf4bb68d35fa287edd
2015-11-12 14:34:24 -08:00
Kunal Mehta 0a0a62e3c3 Allow welcome notifications to have a primary link
Wikis can customize the 'notification-welcome-link' to a page title
(like "Project:Welcome" for example) and the "Welcome!" notification new
users receive will have a primary link to that page.

Bug: T117509
Change-Id: I29f6d69db480fa7d39573941e762c4dad8737ed0
2015-11-12 14:30:51 -08:00
Kunal Mehta fb56d61d68 Fix some phpdoc, add missing @throws
Change-Id: Iba072d64443ed9117233f591f1aea3cc6a4adc44
2015-11-12 14:10:52 -08:00
Translation updater bot 6185098c26 Localisation updates from https://translatewiki.net.
Change-Id: Ia1f33f7449061dfd13516bd9a6938ee6f78c5a0e
2015-11-12 22:59:02 +01:00
Kunal Mehta c6d53ad8ed Remove unncessary code from NotifUserTest
setMwGlobals() already restores global state upon teardown, so this
isn't necessary.

Change-Id: Ia2a2d7a8d3aa3c83443718d5bbf7e7ebd40af472
2015-11-12 11:27:36 -08:00
jenkins-bot bacbd34a94 Merge "Don't export unused wgEchoOverlayConfiguration/wgEchoHelpPage JS variables" 2015-11-12 19:26:52 +00:00
Kunal Mehta 5114aa2c26 Remove unused NotifUser::getFormattedNotificationCount()
As of 0790125dd4, this is unused.

Change-Id: I7d7080cd2c45c14a3fb59fc3b9d224fac8e55dd8
2015-11-12 11:21:56 -08:00
Kunal Mehta 0790125dd4 Don't export unused wgEchoOverlayConfiguration/wgEchoHelpPage JS variables
And make the if conditional a little easier to read: is logged in versus
not anonymous.

Change-Id: I76784b74caabd1ea0a5f0f506661a1682c865394
2015-11-12 10:42:54 -08:00
Translation updater bot 0896dfac1f Localisation updates from https://translatewiki.net.
Change-Id: Ie42cd73989f9f2a8e45a83a17dc2ad5c988362c6
2015-11-11 21:53:05 +01: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
Translation updater bot 8144d6d44e Localisation updates from https://translatewiki.net.
Change-Id: I389952288252d4df169c0433e478d8f5dc58dfaa
2015-11-10 22:34:10 +01:00
Željko Filipin 00524cfebe Added Rakefile
This is needed for our continuous integration.

Bug: T117993
Change-Id: I505de688e73488624cbecc5e644aa1b739ad1f23
2015-11-10 10:25:12 +00:00