Commit graph

2286 commits

Author SHA1 Message Date
Siddharth VP 9d05af9df8 Replace uses of deprecated wfGetDB()
Bug: T357642
Change-Id: I868133bca622ad2af851e874b450fe0be53017d2
2024-03-04 18:39:15 +05:30
Translation updater bot 056fb151e7 Localisation updates from https://translatewiki.net.
Change-Id: I79757339442a5e50220d1ce5ff53c5c600611cfa
2024-03-04 08:23:26 +01:00
jenkins-bot 0b9f7f907d Merge "Introduce MultiGadgetRepo to facilitate repo migration" 2024-03-02 18:43:01 +00:00
Siddharth VP a629d7f71d Introduce MultiGadgetRepo to facilitate repo migration
MultiGadgetRepo is a wrapper around two or more GadgetRepos so that
they can be used at the same, facilitating migration from one repo to
another.

If a gadget appears in both repos, the definition in the first repo
takes precedence, and a warning is shown on Special:Gadgets.

This can be enabled to wrap GadgetDefinitionNamespaceRepo and
MediaWikiGadgetsDefinitionRepo by setting $wgGadgetsRepo to
'json+definition'. In this configuration, once a new JSON definition
exists for the same name, it is used instead of the old one, and the
old one can then safely be removed at a later time in the safe
knowledge that it is no longer used.

Adapted from If3cc5e22e9812d0fd1a9e8e269ea74a7f667dadd

Bug: T140323
Co-authored-by: Kunal Mehta <legoktm@debian.org>
Change-Id: Ibad53629e63ec8713d7a3b84a19838b94600588e
2024-03-02 18:22:04 +00:00
Translation updater bot 773af86f13 Localisation updates from https://translatewiki.net.
Change-Id: Ibff44c7bd8349e26056fd04252b6d302f63750ae
2024-02-29 08:36:00 +01:00
Translation updater bot 820a010016 Localisation updates from https://translatewiki.net.
Change-Id: I6d53731629c54c66d2888ffa83a8aa3145fc8175
2024-02-26 08:36:07 +01:00
jenkins-bot a5707f810e Merge "tests: Widen @covers annotations" 2024-02-24 16:56:15 +00:00
jenkins-bot af3ab84860 Merge "Content: Use DI for GadgetRepo service" 2024-02-24 16:51:09 +00:00
jenkins-bot 88e934c6cb Merge "Goodbye Gadget/Gadget_definition namespaces!" 2024-02-24 16:50:56 +00:00
Translation updater bot 305ef9b6ce Localisation updates from https://translatewiki.net.
Change-Id: I34e80febbc04435f64bf3820ce76a0b1b8f19187
2024-02-23 08:44:27 +01:00
Translation updater bot 1093394176 Localisation updates from https://translatewiki.net.
Change-Id: I979a52f6620f13b716e5833f58406cef74644426
2024-02-22 08:43:35 +01:00
Bartosz Dziewoński 9cc4ff546e Use OutputPage::setPageTitleMsg() instead of ::setPageTitle()
Bug: T343994
Change-Id: I71d1ffabd3fca96c6a3b2a9f1647edf9e675e332
2024-02-17 02:57:11 +01:00
Translation updater bot d8130a9cb0 Localisation updates from https://translatewiki.net.
Change-Id: I7fbc148288412de930e2d5c9acd8de6ebbd99649
2024-02-15 13:28:16 +01:00
Translation updater bot c8a8348fd9 Localisation updates from https://translatewiki.net.
Change-Id: I1bf93d9e612090fa09fc4d01a030ba48a7eb6793
2024-02-14 08:18:48 +01:00
Timo Tijhof 9b6d34ddf2 tests: Widen @covers annotations
https://gerrit.wikimedia.org/r/q/owner:Krinkle+is:merged+message:%2522Widen%2522

Change-Id: I1d2a75a7f64500b81f95d895ce065e80e336fba7
2024-02-13 16:11:35 +00:00
Timo Tijhof 107428075e Content: Use DI for GadgetRepo service
Change-Id: Idfabb0dfc15bdb9527f7a0018313dc9606cbd715
2024-02-13 13:45:30 +00:00
Timo Tijhof fce6fdfb20 Goodbye Gadget/Gadget_definition namespaces!
== What ==

* Remove the empty Gadget and Gadget_definition namespaces.
* Remove the "gadgets-definition-edit" user right.
* Remove need for custom namespace permissions that previously
  had to extend editsitejs to apply to NS_GADGET.

== Why ==

Simplify the (unused) "GadgetDefinitionNamespaceRepo" backend for
Gadgets 2.0 by making it less radically different from the status quo.

The experimental 2.0 branch will now make use of the "gadget definition"
content model via "MediaWiki:Gadgets/<id>.json" pages, instead of
through a dedicated namespace.

When I first worked the Gadgets 2.0 branch, content models
were not a thing in MediaWiki, and interface-admin wasn't a thing yet
either. Now that we have per-page permissions and per-page content
models, we don't really need a separate namespace.

This follows the principle of least surprise, and fits well with other
interface admin and site configuration tools such as:
- Citoid, MediaWiki:Citoid-template-type-map.json,
- VisualEditor, MediaWiki:Visualeditor-template-tools-definition.json,
- AbuseFilter, MediaWiki:BlockedExternalDomains.json,
- the upcoming "Community Config" initiative.

If/when we develop the SpecialPage GUI for editing gadget definitions,
this can save its data to these pages the same as it would in
any other namespace. Similar to how Special:BlockedExternalDomains
operates on MediaWiki:BlockedExternalDomains.json.

See also bf1d6b3e93 (I6ffd5e9467), which recently removed the
gadgets-edit user right in favour of the editsite{css,js,json} rights.

Change-Id: I5b04ab251552e839087d0a8a6923d205adc7f771
2024-02-13 13:30:26 +00:00
Translation updater bot 64c44829b9 Localisation updates from https://translatewiki.net.
Change-Id: I41e50302641f7b7bedc4912b0cb811957c27e534
2024-02-12 14:49:39 +01:00
libraryupgrader 00ce2a1e58 build: Updating dependencies
composer:
* mediawiki/mediawiki-phan-config: 0.12.1 → 0.14.0

npm:
* grunt-banana-checker: 0.11.0 → 0.11.1

Change-Id: I5af3357248500669710cd4bdb3bc4f788392415a
2024-02-10 17:22:54 +00:00
jenkins-bot ac7cec5d57 Merge "Move "gadgets" message to "special-gadgets"" 2024-02-10 00:27:29 +00:00
Timo Tijhof a8c3eb1282 Move "gadgets" message to "special-gadgets"
This makes way for "MediaWiki:Gadgets/<id>.json" to be used free of
any confusion or misinterpretation about the subpage being a
translation of "MediaWiki:Gadgets".

Change-Id: Icb68ce6c26a83d7201a97a5406f8752b3c5b0855
2024-02-09 19:10:54 +00:00
libraryupgrader 862f3b5e2e build: Updating npm dependencies
* eslint-config-wikimedia: 0.25.1 → 0.26.0
* grunt-eslint: 24.2.0 → 24.3.0

Change-Id: Ic0bb253bdf98fa02fb1dacd9cc2c6c34867d1f50
2024-02-09 03:48:56 +00:00
jenkins-bot c6b47d5bfd Merge "Follow-Up 27f913cc96: Drop complicated MobileContext injection, now unused" 2024-02-07 18:15:34 +00:00
Translation updater bot 86000a8718 Localisation updates from https://translatewiki.net.
Change-Id: I19ae09d1edb8ae8fdb4bc8ad33eb53d1be466526
2024-02-05 08:49:44 +01:00
libraryupgrader ac42f4ee8e build: Updating npm dependencies
* eslint-plugin-compat: 4.1.4 → 4.2.0
  * https://github.com/advisories/GHSA-c2qf-rxjj-qqgw
  * https://github.com/advisories/GHSA-c2qf-rxjj-qqgw
  * https://github.com/advisories/GHSA-c2qf-rxjj-qqgw
* semver: 7.3.8 → 7.5.4
  * https://github.com/advisories/GHSA-c2qf-rxjj-qqgw
  * https://github.com/advisories/GHSA-c2qf-rxjj-qqgw
  * https://github.com/advisories/GHSA-c2qf-rxjj-qqgw

Change-Id: I130054bdeb83e505f96378adc077526e8f7dbf32
2024-02-03 20:55:23 +00:00
Reedy 1b2a84aaff Gadget: Bump GADGET_CLASS_VERSION
Bug: T356322
Follows-Up: If6d742ea719e4c8db9d915e8297d915d2150ef50
Change-Id: Id5f60e054304e6a715f0f54d11fd2f467fe4c5c7
2024-01-31 19:37:07 +00:00
Translation updater bot 5ec56bef7d Localisation updates from https://translatewiki.net.
Change-Id: I82f87498d700c4be85ef94bd0dd03c273aa8fae0
2024-01-31 08:29:04 +01:00
Translation updater bot 11fa3db4a4 Localisation updates from https://translatewiki.net.
Change-Id: I7c634517cd4dfbf7bbcf967ce726d239870fae6a
2024-01-30 09:39:04 +01:00
Translation updater bot e87235edaf Localisation updates from https://translatewiki.net.
Change-Id: Icb93c28cc7e06f137617865c45da70b6b405ced1
2024-01-28 16:06:41 +01:00
James D. Forrester 9d6b0e8206 Follow-Up 27f913cc96: Drop complicated MobileContext injection, now unused
Change-Id: I8b32abd4bcc0b588972c65956d08c4b29bf6b4aa
2024-01-26 12:48:18 -05:00
James D. Forrester 27f913cc96 Drop RL targets definitions from module class, and validation / error code
Bug: T328497
Change-Id: If6d742ea719e4c8db9d915e8297d915d2150ef50
2024-01-24 12:11:20 -05:00
jenkins-bot 677e3a86ff Merge "Make Special:Gadgets [Edit description] link smaller" 2024-01-24 00:51:15 +00:00
jenkins-bot 705c01a7ca Merge "SpecialGadgets: refactor" 2024-01-19 09:26:20 +00:00
Translation updater bot b0cb91e055 Localisation updates from https://translatewiki.net.
Change-Id: I5a33f2fa139b25e0139e7b02ed8025ad31799c65
2024-01-19 09:17:01 +01:00
Novem Linguae cc22098a48 Make Special:Gadgets [Edit description] link smaller
To match the style of section [edit] links in articles.

Bug: T344489
Change-Id: Ic3fd864a7b2889ba246418d4a781fd8db29f5ce9
2024-01-18 16:49:16 -08:00
Novem Linguae 5b656b1ee9 SpecialGadgets: refactor
Improve code grouping and comments.

Change-Id: I67fd8081fb5e47bd5a13c85b68433d9a90b67c05
2024-01-18 16:44:43 -08:00
jenkins-bot da62832dde Merge "SpecialGadgets: better variable names" 2024-01-18 23:21:01 +00:00
jenkins-bot 4ca73e1556 Merge "SpecialGadgets: convert Xml class to Html class" 2024-01-17 18:08:04 +00:00
Novem Linguae e62314d4ba SpecialGadgets: fix docblock type mistake
Change-Id: I1716c0c4b74ec34d6b8b69316fb397aa1de3b8bc
2024-01-17 08:02:14 -08:00
Novem Linguae 209c626d66 SpecialGadgets: better variable names
Change-Id: I515d4016a3cb4a9eeb2488a39afa2b5d48a2dc48
2024-01-17 07:59:17 -08:00
Novem Linguae eeb4740fbc SpecialGadgets: convert Xml class to Html class
Change-Id: I8a24789a11ad5f494dc0f9a87642b1b79b40fd3b
2024-01-17 07:50:21 -08:00
Translation updater bot baff83d550 Localisation updates from https://translatewiki.net.
Change-Id: I58d3aefa499ab19d0f7a70b4c7e0469abf608563
2024-01-17 08:37:18 +01:00
Translation updater bot 4b656f781d Localisation updates from https://translatewiki.net.
Change-Id: Icabbb59cf05b0eb64854a0a3ad3eec35032a2570
2024-01-16 08:25:44 +01:00
Translation updater bot 474e6d7d55 Localisation updates from https://translatewiki.net.
Change-Id: I629f7a203e613030587c43c8d5ca7f794d6fe41b
2024-01-15 08:24:27 +01:00
Translation updater bot 549e9c015d Localisation updates from https://translatewiki.net.
Change-Id: I8bdfa3981c37668489f8ad700943edb06a100a17
2024-01-12 09:00:18 +01:00
jenkins-bot 50d2405a43 Merge "Add validations for skins and rights" 2024-01-11 17:03:15 +00:00
Translation updater bot 2687909023 Localisation updates from https://translatewiki.net.
Change-Id: I51cef8c72f460501026f9c064d0fe34b24e59e9f
2024-01-11 10:04:15 +01:00
Siddharth VP b944152d3a Add validations for skins and rights
Bug: T298334
Change-Id: If32b334f331845eab6c115f40f8dcf4534028c9c
2024-01-11 10:02:40 +05:30
jenkins-bot f55a46c3f1 Merge "Avoid global RequestContext in GadgetRep::validationWarnings()" 2024-01-10 07:59:12 +00:00
Translation updater bot 7a9cf54022 Localisation updates from https://translatewiki.net.
Change-Id: I7cee8d0a9599b714042a924f9bb5a0035f61c6bb
2024-01-10 08:32:55 +01:00