Commit graph

953 commits

Author SHA1 Message Date
Bartosz Dziewoński 66b1ca1578 ApiDiscussionToolsPreview: Add missing documentation messages
Bug: T342634
Change-Id: If550d6ccf6fb8256d2f252d796f8bc4651dc8f7b
2023-08-04 20:55:13 +02:00
jenkins-bot f86bd42f01 Merge "Enable automatic topic subscriptions for autocreate accounts" 2023-08-01 16:38:27 +00:00
Ed Sanders eb8a689069 Enable automatic topic subscriptions for autocreate accounts
Bug: T332618
Change-Id: I0a9ed795b7a28365bca199a2db44217e53063002
2023-07-31 13:39:46 +01:00
Ed Sanders e389fc48f1 Always use === in PHP
Change-Id: I30ca7cdf73921dcae48997841816099972cdbed0
2023-07-26 14:29:40 +01:00
jenkins-bot 5bf0110b4b Merge "Replace uses of UserNameUtils::isTemp with UserIdentityUtils::isTemp" 2023-07-26 12:54:48 +00:00
jenkins-bot e0763d81ed Merge "Use strict comparison with array_search" 2023-07-26 12:09:21 +00:00
Thalia ec8048131d Replace uses of UserNameUtils::isTemp with UserIdentityUtils::isTemp
Where a UserIdentity is available, use UserIdentityUtils, which has
fewer dependencies.

Change-Id: I035bfbc7801f4ac77a8c6f0991f0fdf71b8fb429
2023-07-26 11:32:27 +01:00
Ed Sanders 1bb29faa58 Use strict comparison with array_search
Change-Id: Id920d49701bd9436a6247763ed40df052877ad2f
2023-07-24 18:50:00 +01:00
Bartosz Dziewoński 1b80b1ffcf ThreadItemStore: Look harder for invisible rows
This reverts 08e1073f58 (T322701),
which does not work, and instead uses the same solution as
4439e934429617cc77f34cc9c783f0b52a06c920 (T247553).

Bug: T339882
Change-Id: I1b6772b1cdfd0d7e1c603333a2e43152d3591c38
2023-07-16 00:45:52 +02:00
jenkins-bot 218d3aea38 Merge "Backend changes related to topic subjects in message body" 2023-07-11 15:21:50 +00:00
jenkins-bot 7b147cffbf Merge "ApiDiscussionToolsPageInfo: Allow excluding signatures" 2023-07-11 15:17:02 +00:00
jenkins-bot 5b2d1046ad Merge "Reload page or redirect when saving an edit creates a temp account" 2023-07-11 15:16:59 +00:00
jenkins-bot ce286af8dc Merge "Suppress the empty state in previews again" 2023-07-11 13:59:49 +00:00
Bartosz Dziewoński 90f8fe5ec1 Reload page or redirect when saving an edit creates a temp account
Depends-On: I6cdc014fb39d35ce1f091b53dc3a9c4a3c95f9e9
Depends-On: I01e13ce1ebab462eeb0ba3847d4205a88965a127
Bug: T338002
Change-Id: I768e4fa2030d781bbc65428371bda17a87bd6a42
2023-07-10 22:55:58 +00:00
jenkins-bot cb700abb8c Merge "SpecialFindComment: Allow spaces instead of underscores in the input" 2023-06-24 10:40:20 +00:00
Bartosz Dziewoński 80746017bb SpecialFindComment: Allow spaces instead of underscores in the input
Our IDs and names are correctly written with underscores, but allow
spaces too for consistency with the behavior of internal wiki links
when linking to a subpage of Special:FindComment.

Change-Id: Ib9f67ac02d963395db9d56951946b9747a410a88
2023-06-24 10:47:48 +02:00
jenkins-bot 6de3603990 Merge "ApiDiscussionToolsEdit: Allow not returning the new revision content" 2023-06-22 21:31:32 +00:00
Bartosz Dziewoński 14d9652a78 Backend changes related to topic subjects in message body
Our edit API now recognizes topic subjects in the message body,
generates edit summaries from them, and optionally returns an error
if no subject is provided.

Bug: T334163
Bug: T338390
Change-Id: Iac3778a4a88a4def234be9d10b80d9796d35bceb
2023-06-22 10:35:04 +02:00
Bartosz Dziewoński aa239a1ad1 Suppress the empty state in previews again
It wasn't appearing in normal previews thanks to some redundant checks
elsewhere, but it was appearing in our own internal previews using
ApiDiscussionToolsTrait::previewMessage(). It wasn't causing any
problems until change Iac3778a4a88a4def234be9d10b80d9796d35bceb, which
detects headings in the preview, and it was detecting the empty state
heading.

Follow-up to commits 8fb467896f and
ab40ef62c0, where I replaced a HTML
comment with ParserOutput extension data to indicate this, and then
accidentally removed the cleanup code from removeInteractiveTools()
with no replacement.

Change-Id: I4b650f82c711d65e200758e981ce338202deeaa6
2023-06-22 10:31:29 +02:00
jenkins-bot 0c7c7de242 Merge "Support ISO 8601 timestamps in the parser" 2023-06-19 12:31:58 +00:00
Theodore Dubois 4ca17b8c33 Support ISO 8601 timestamps in the parser
https://wikipesija.org is currently using ISO 8601 as the default date
format. The format is xnY-xnm-xnd"T"xnH:xni:xns and 'xn', 'm', and 's'
need support added.

Change-Id: I235098a578eb92ddd23ea47fa23d60df4b28f590
2023-06-17 11:36:43 -07:00
Bartosz Dziewoński b405fd9b40 Make topic subscriptions unavailable to temp users
Bug: T332432
Change-Id: Icf91f0900ef3435cf3e9eedcf983e61ad9aeea69
2023-06-13 01:05:55 +02:00
Bartosz Dziewoński 6bf6105d2a ApiDiscussionToolsEdit: Allow not returning the new revision content
Sometimes we call this API and then reload the page (or navigate to
another URL), without using the page content it returns. Save some
work and some data transfer and don't generate it in those cases.

Depends-On: Ic5fac61f3ef9b2dfce6ff757f1d414a9f41f217d
Change-Id: If1aea90488e3f22cc31ac1f360139ae65acf000a
2023-06-12 20:28:45 +00:00
jenkins-bot b6ebb59c5f Merge "EchoHooks: Use symbols instead of string class names" 2023-06-09 20:59:21 +00:00
Ed Sanders 531ced9e31 EchoHooks: Use symbols instead of string class names
Change-Id: I3a4bba84d939f23653b719a271cecaa9395f0cd0
2023-06-09 22:33:27 +02:00
thiemowmde 0cf68818a8 Add various, more specific type hints
* Add @var comments to untyped getService() calls so IDEs and tools
  are able to understand where the callers are.
* Use the more specific IReadableDatabase where possible.
* Fix missing import.

Change-Id: I9c1153cb9fe872227753628a947f40bd5ee447fa
2023-06-09 13:44:42 +02:00
jenkins-bot f9580e6817 Merge "Use namespaced Echo classes" 2023-06-08 13:25:14 +00:00
Siddharth VP 03fcb20810 Use namespaced Echo classes
Change-Id: Id1673cb6ec0ae5f9177db28414d46d216fcabb45
2023-06-08 13:46:31 +05:30
Ed Sanders 0672f4c74a Remove DiscussionToolsEnableMobile
This existed to do a staged rollout to WMF wikis.

Bug: T322497
Change-Id: I4562c166f3f07bce972f9d599de211147d2dc631
2023-06-06 13:25:21 +01:00
Ed Sanders 99f132f05e Remove most DiscussionTools feature configs
Only visual enhancements are yet to be made available everywhere.

Bug: T322497
Change-Id: Ia8a7673f23d1ee31bb7e53d8e75f982d1e48d1ec
2023-06-06 13:25:19 +01:00
Ed Sanders 3b4673bfad Drop the DiscussionToolsEnable feature flag
This existed to do a staged rollout to WMF wikis, which was
finished in March 2021 (T276497).

Bug: T322497
Change-Id: I8851f0243e6920d93f3eb1870d1604bf201ed5a4
2023-06-06 13:08:35 +01:00
Ed Sanders dda86f8ebf Always use the strict equality flag when using in_array
Change-Id: Ia09f5aadc3bbf64645ba174f047e53db49e07925
2023-06-06 13:08:00 +01:00
jenkins-bot a1d0e3a9d3 Merge "Create HookRunner class and the hook handler interface" 2023-06-05 22:12:23 +00:00
Umherirrender 378769a974 Create HookRunner class and the hook handler interface
Bug: T273303
Change-Id: I6d00848f07fc7d17f3dc7f44b7b6b61553219558
2023-06-04 20:12:56 +02:00
Bartosz Dziewoński e65b49ec43 Don't try to set preferences for temporary accounts
Bug: T337784
Change-Id: I34d35673e5d2651e1da10ba0e7946a0bd54312ea
2023-06-02 20:11:52 +02:00
Bartosz Dziewoński 2d40cbb6d5 ApiDiscussionToolsPageInfo: Allow excluding signatures
Special:DiscussionToolsDebug falsely promised that the API delivers
the same information, but in fact the API included the signatures in
each comment's HTML unconditionally. Allow excluding them.

Change-Id: Ie1e38d28bed0b6d5713d9051b84cc08a23da94c2
2023-05-30 15:55:41 +02:00
Bartosz Dziewoński fda08f7b54 Remove the new topic tool hint
This temporary message has been shown for long enough.

This mostly reverts:
* d0eec56f6d
* f24a73a05a
* bd40523843

Bug: T322495
Change-Id: Ic1762e170547fba8b5fda225eff21e515ace512d
2023-05-24 20:15:49 +02:00
jenkins-bot 4bcee681fc Merge "Make use of named MainConfigNames::… constants" 2023-05-19 13:23:17 +00:00
gerritbot 3f2cfa423b Update moved class RawMessage
See T321882. Moved in I195cf4c67bd514

Bug: T321681
Change-Id: I6c456405dc038fff7aa3124fdb4b9d6be0d0ffcb
2023-05-19 10:30:50 +00:00
thiemowmde 8bbbf39bbd Make use of named MainConfigNames::… constants
Also merge setMwGlobals() calls because they are really expensive.

Also utilize the more readable str_contains() and related.

Change-Id: Iebde6aa17c2e366f0c0a98fe13a454f6a06c299b
2023-05-19 12:12:32 +02:00
jenkins-bot 25b3366070 Merge "Add talk page empty state for temporary accounts' user talk pages" 2023-05-16 17:51:54 +00:00
Bartosz Dziewoński e3441be186 Add talk page empty state for temporary accounts' user talk pages
Depends-On: I2ea656a8a1704a495f1a94fede1a8829ba7325a1
Bug: T335590
Change-Id: Ibe1ea316f5da450b4478bf466ec12bbca9a91cd2
2023-05-16 17:00:03 +00:00
David Lynch 71d2e76d7f Update a/b test code for visual enhancements a/b test
Strip it out from applying to logged out users and make the test work
for multiple features

Bug: T333715
Change-Id: Id15a8a99c2ea8e6fc14fc83baf2ed6ebaaf754c8
2023-05-08 01:30:21 -05:00
Amir Sarabadani 40c3c65ccf Switch from typehinting ILBFactory to IConnectionProvider
Narrower interface

Change-Id: Id94d098089f1db645ea6b4b4eb516a512c66fdb2
2023-04-29 23:00:59 +00:00
jenkins-bot d74fff198d Merge "Add an API version of Special:FindComment" 2023-04-26 18:02:09 +00:00
Ed Sanders 0be67d3f20 Add an API version of Special:FindComment
Bug: T333375
Change-Id: I02f032b0a36d384b9ac9e397106eb30d325421d8
2023-04-26 17:09:15 +01:00
Bartosz Dziewoński 355c6b2e7b Remove no-JavaScript topic subscriptions cached HTML compat
Bug: T321431
Change-Id: Iae3defa220762ca8edd45f461b062987b17e4f5f
2023-04-25 16:18:31 +00:00
gerritbot 605b6f96bf Update moved class WikiMap
See T321882. Moved in I60cf4b9ef02b9d5

Bug: T321681
Change-Id: I2381ae00735c6924eba97141e3194ee111f75cc7
2023-04-25 09:53:18 +00:00
Bartosz Dziewoński 0d21df43dc Allow maintenance script to work even when DiscussionToolsEnablePermalinksBackend is off
Bug: T334258
Change-Id: I40e09b2f8561eeac1744bbbc48e3973e519bd9ea
2023-04-14 19:36:18 +02:00
Bartosz Dziewoński f681188d57 Update talk_page_edit logging for IP masking
Bug: T332437
Bug: T332432
Change-Id: I6ffd6b48e683a82065da35241110fd32888d2c4e
2023-04-11 21:52:05 +02:00