Commit graph

1587 commits

Author SHA1 Message Date
Bartosz Dziewoński 067f0c36de Config option to enable topic subscriptions backend and dtenable=1 URL parameter
…without making the topic subscriptions feature available in user preferences.

Follow-up to these commits, which added these checks in ad-hoc ways:
* 9420f22e9d
* f3422f40a6
* 23a490deca
* a555db7892

Bug: T284491
Change-Id: If2e3fb1e06d1cc489fbca14796ed77c83bb52991
2021-06-14 16:18:18 +02:00
Translation updater bot 6f0c5f26c0 Localisation updates from https://translatewiki.net.
Change-Id: I4f0fa84fae77142e5aa712a5c085f9ee9bd1a992
2021-06-14 08:36:42 +02:00
jenkins-bot 9ea5d8375c Merge "Reply tool: Disable preformatted command" 2021-06-10 20:21:33 +00:00
Translation updater bot fdadd19ce4 Localisation updates from https://translatewiki.net.
Change-Id: I2daffe12505362a78551da7078bd05f9351738ee
2021-06-10 08:34:19 +02:00
Ed Sanders c41dab81c4 Reply tool: Disable preformatted command
Preformatted text can't be rendered in wikitext when indented.

Change-Id: I2269471dd76630661cdb459322df591c6b3e6a50
2021-06-08 23:02:59 +01:00
jenkins-bot d1576ad40b Merge "Update surface styles for VE changes" 2021-06-08 16:35:00 +00:00
Bartosz Dziewoński c51638e940 Update surface styles for VE changes
The .ve-init-mw-target-surface class is no longer added since
Ic5320f6747907542285674d386c7a59c9e857f0a.

Also apply changes similar to I8d20a830dc48f6a098b0f9e9a7c7c1656de0fe56
to avoid potential styling issues with nested surfaces.

Bug: T284567
Change-Id: I58a49f0137e8804fbd73de20048eb2ffdbbfbe77
2021-06-08 18:04:21 +02:00
Translation updater bot 3bf067bb8d Localisation updates from https://translatewiki.net.
Change-Id: Iadf0ce9509da5c7012c76faebbe3181118d3fe19
2021-06-08 08:35:55 +02:00
Translation updater bot d18315f850 Localisation updates from https://translatewiki.net.
Change-Id: I0495ec5fc32d59ff54b49b412c60a5426126a8f0
2021-06-07 08:41:52 +02:00
Translation updater bot 441079b6d0 Localisation updates from https://translatewiki.net.
Change-Id: I5536cc1216dd2cb0a7dd0c472a106ff91af2ee4d
2021-06-04 08:36:18 +02:00
jenkins-bot c5c4c86185 Merge "Change how highlights are positioned to work better with unaware tools" 2021-06-03 12:11:25 +00:00
Bartosz Dziewoński bd27a46deb Fix revealing content of deleted revisions in notifications
If the revision from which we generated the notification has been
deleted, we shouldn't include the content snippet, nor the direct link
to the comment (because the fragment ID is generated from the content).

This matches how Echo handles mention notifications.

Change-Id: Ica939f3a4efd39d0c295511d58280d3f9d584129
2021-06-03 02:45:15 +02:00
Bartosz Dziewoński 0dfb34eb50 Avoid parsing the comment snippet in notifications as wikitext
As it happens, most of Echo does not actually parse this message,
but it is for some reason parsed in HTML email notifications.

Change-Id: I414cd242d9bcc4d8b5a1c2a2a71be9e5f00ea8be
2021-06-03 02:43:56 +02:00
Bartosz Dziewoński fd080b7043 Ensure you can't get duplicate notifs for edits to your user talk page
We don't display [subscribe] buttons on your user talk page,
but the API still allows those subscriptions.

Use the same approach as for mentions to ensure this doesn't cause
duplicate notifications.

Remove some code in SubscribedNewCommentPresentationModel,
now guaranteed to be unused.

Change-Id: I99a276a48d8562552ed2c54cc0323e8e428845fd
2021-06-03 02:10:33 +02:00
Bartosz Dziewoński 4353b68646 EventDispatcher: Read revision IDs to compare from master
Bug: T284175
Change-Id: Iec99ea0afc659969108104cf5b2627856711544d
2021-06-02 19:47:35 +00:00
Bartosz Dziewoński 9c8d709b8a Use placeholder localisation messages in CommentFormatter tests
Otherwise they will fail whenever translations are updated
(and they are failing right now).

Change-Id: I849c57b86d36fb6c7739cc31a74df741e08462f4
2021-06-02 21:46:36 +02:00
Translation updater bot cf1af27f32 Localisation updates from https://translatewiki.net.
Change-Id: I5c867270835bb40ff825f508d0e16c8d6eea8e93
2021-06-02 14:35:05 +02:00
Ed Sanders 5a166cfab5 Notification unsubcribe button
Bug: T279150
Change-Id: Ib0bfe3c0dced2108bddbc837a7ddd7bea814e129
2021-06-01 23:29:53 +02:00
jenkins-bot ea98787f41 Merge "Apply transformations in ParserCache for all CommentFormatter features" 2021-06-01 19:24:04 +00:00
Ed Sanders 6a24ceaeca Subscribe/unsubscribe with plain text links
Bug: T279149
Bug: T279151
Change-Id: Ie7d46ea2e8d458fcdad4f91bb89ba038969f6b62
2021-06-01 20:37:47 +02:00
Translation updater bot f6af99c3e0 Localisation updates from https://translatewiki.net.
Change-Id: Ie737b72809d598a19693d399b4cee34747cdca62
2021-06-01 08:35:05 +02:00
Bartosz Dziewoński 9c58c0a203 Change how highlights are positioned to work better with unaware tools
Previously, our highlights were placed in a node at the end of
the page, and positioned absolutely in relation to the whole
page. Now we insert the highlight in the DOM near the comment,
and position it in relation to that.

This way it remains positioned correctly when the page shifts
(e.g. collapsing the table of contents), and disappears when
the page content is hidden (e.g. opening visual editor).

Bug: T281471
Change-Id: I60afc4b94b2e23376105638542563e595a1811d9
2021-05-31 23:07:02 +02:00
Translation updater bot 9bbbf967ac Localisation updates from https://translatewiki.net.
Change-Id: I850f95e4d1819a34b5b3aec85847c4486d3215ea
2021-05-31 08:30:52 +02:00
jenkins-bot 3759ffdd2a Merge "Swap DOM order of summary and watch checkbox" 2021-05-30 12:42:35 +00:00
jenkins-bot e5e1d9e86c Merge "Follow-up: Adjust comment ranges to exclude the start marker *only*" 2021-05-30 12:41:36 +00:00
Translation updater bot e7c0545306 Localisation updates from https://translatewiki.net.
Change-Id: Ie4623d21742f6de529dc3fbe7055b5040a95398c
2021-05-28 09:03:51 +02:00
Bartosz Dziewoński 90fdd12efd Swap DOM order of summary and watch checkbox
This is to achieve the same tabbing order as the wikitext editor.

Bug: T271773
Change-Id: I7e167ed8a5aa9b9862f215cba7539b7f79315037
2021-05-27 23:24:25 +02:00
Bartosz Dziewoński 7b21e29405 Follow-up: Adjust comment ranges to exclude the start marker *only*
The modifier crashes if endContainer is a <p>/<dd>/<li> node, and
it often is if we try to exclude the end marker from the range.
It doesn't matter for T281471, so let's just leave it that way.
(This is also more similar to the range produced by our parser.)

Follow-up to c4ba8e921a. No idea how
I missed this when testing that patch.

Also, improve comments.

Bug: T281471
Change-Id: If6aba34acf29c37d06fb0ca92547f78b58695597
2021-05-27 21:28:39 +02:00
Bartosz Dziewoński c4ba8e921a Adjust comment ranges to exclude the start/end markers
This produces nicer results when we call Range#getBoundingClientRect
on them later, when drawing comment highlights (using Firefox).

I'm not sure how this will affect everything in modifier, but it
doesn't seem to be causing issues. If it does cause trouble, then we
should instead adjust the range this way in controller#highlight.

Bug: T281471
Change-Id: I6f204b858990023f42f564cca7a2d24d322f872e
2021-05-27 15:19:08 +00:00
Translation updater bot ce16e7e90f Localisation updates from https://translatewiki.net.
Change-Id: I75e256a32def869323f986f9cfa09f9ef02d365b
2021-05-27 12:05:09 +02:00
jenkins-bot 04df0fc9fb Merge "Highlight target comment when following a link or notification" 2021-05-26 19:46:56 +00:00
jenkins-bot 939810f8fe Merge "Change feedback link for new topic tool" 2021-05-26 18:59:28 +00:00
jenkins-bot ffcbce4f2d Merge "Pass whole context to internal action API requests" 2021-05-26 16:46:13 +00:00
jenkins-bot ef413b73e6 Merge "Limit number of topic subscriptions per user" 2021-05-26 13:01:06 +00:00
jenkins-bot 052573efe1 Merge "Use the edited page's title for magic words in API error messages" 2021-05-26 13:00:11 +00:00
Bartosz Dziewoński fffffe8f8f Pass whole context to internal action API requests
Otherwise, the global context is used (RequestContext::getMain()),
which is undesirable when you're building a rubegoldbergian
contraption and we're already inside an internal action API request
with a fake context.

Change-Id: I01daf8dc70b5751bc1e157fe598988cd5d3219e5
2021-05-26 12:55:33 +00:00
Ed Sanders 2b3345af11 Change feedback link for new topic tool
Bug: T279400
Change-Id: I5d72552f45a63199c0fbb516dc94aef19945c95e
2021-05-26 11:27:01 +00:00
Translation updater bot 1f2d9e5a9f Localisation updates from https://translatewiki.net.
Change-Id: I7fc6a8cd2ebb56a8fea1319514292e5576316d36
2021-05-26 09:04:23 +02:00
jenkins-bot e56a8ad756 Merge "Allow the widget to be squished next to floating elements" 2021-05-25 20:55:16 +00:00
jenkins-bot 5a6265dbe5 Merge "Add notifications feature to beta feature copy" 2021-05-25 20:12:56 +00:00
jenkins-bot 90528f2b49 Merge "Fix adding comments in lists containing <dt> tags" 2021-05-25 19:19:49 +00:00
jenkins-bot 86732c56dd Merge "modifier: Guard against infinite loop" 2021-05-25 19:17:53 +00:00
jenkins-bot 14035f3c7e Merge "Remove cookie hack for loading unavailable tools" 2021-05-25 19:17:19 +00:00
jenkins-bot 2d6b8350f5 Merge "Allow talk pages to have a different ParserCache expiry" 2021-05-25 18:49:48 +00:00
Bartosz Dziewoński 0968d2203b Allow the widget to be squished next to floating elements
Bug: T278476
Change-Id: I8e997bbd9ee7bc50baf4e69bde2dda286505b006
2021-05-25 18:44:43 +00:00
Bartosz Dziewoński ee524d6bd6 Remove cookie hack for loading unavailable tools
Bug: T277783
Change-Id: I521db842b4b7a98d8d255d418abd0ccb167c5aa0
2021-05-25 20:27:46 +02:00
Bartosz Dziewoński 6a50d1203c Limit number of topic subscriptions per user
Per Manuel Arostegui in T263817#7033384. The limit is 5000.
(I picked it arbitrarily, there's no real rationale for it.)

Also log a warning when any user reaches half of the limit,
so that we might make a decision about changing this mechanism
before it starts affecting users. Maybe at that time we'll
have data to show that it's safe to remove the limit.

Bug: T263817
Change-Id: I18a8ee0ad7383759229c5721d5253fb591457d4d
2021-05-25 17:16:24 +02:00
libraryupgrader 9974268b13 build: Updating browserslist to 4.16.6
* https://npmjs.com/advisories/1747 (CVE-2021-23364)

Change-Id: Iec1ae4a901a852cfdd739d2727f10c6b9ebd18d1
2021-05-25 10:51:11 +00:00
Translation updater bot bdd019bffd Localisation updates from https://translatewiki.net.
Change-Id: I867b2e0d9b59b5abce81e4a93e2bbcdde29cd311
2021-05-25 08:52:05 +02:00
jenkins-bot 3bea7fe77b Merge "Remove unused 'inTargetWidget' config" 2021-05-24 20:53:20 +00:00