MediaWiki-extensions-GadgetsComponent
ActivePublic

Members (4)

Watchers (11)

Details

Description

PHP extension to allow users to enable JS-based, user-provided gadgets from their preferences page (Homepage). This is not meant for reporting bugs or problems with local gadgets themselves.

Recent Activity

Thu, Jun 27

MaryMunyoki edited projects for T337542: Namespace "gadget" name in Sicilian, added: LPL Technical Support (LPL Technical Support (Current)); removed Language-Technical Support.
Thu, Jun 27, 6:36 PM · LPL Technical Support (LPL Technical Support (Current)), MW-1.41-notes (1.41.0-wmf.13; 2023-06-13), MediaWiki-extensions-Gadgets, I18n

Wed, Jun 26

Od1n added a comment to T299071: Hidden gadget "preferences" being exported in mw.user.options .

Just mentioning this discussion I opened, wondering if an hidden gadget will surely become loaded for everyone if the "default" keyword is added afterwards, i.e. not at the time the gadget definition was created.

Wed, Jun 26, 8:19 PM · MW-1.38-notes (1.38.0-wmf.18; 2022-01-17), MediaWiki-Core-Preferences, MediaWiki-extensions-Gadgets

Mon, Jun 24

PerfektesChaos added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

Would it be difficult to bring compatibility with AJAX previews… if ever it's feasible?

Mon, Jun 24, 10:54 AM · MediaWiki-extensions-Gadgets
Od1n added a comment to T63007: Allow specifying when a gadget should load (action, namespace, content model).

[…] but |namespace=-1 also would fit how special pages are dealt with (if that isn't already supported).[…]

namespace=-1 should already work indeed. The reason I suggest also supporting specials as an action is because a number of gadgets enhance the functionality of wikitext textareas, which appear on action=edit in many different namespaces, and on special pages like Special:Upload. action=edit would mean we (correctly) avoid loading the gadget on page views, but also (currently) makes it impossible to load on Special:Upload. namespaces=0,-1 would correctly load both on edit page and upload page, but would also load during page views. From a routing perspective, special pages are the equivalent of action="" or action=null, but to avoid hardcoding that or locking into no other possibilities in the future, I was thinking action=specials could represent that for completion within the Gadgets extension.

Mon, Jun 24, 9:23 AM · User-notice-archive, MW-1.42-notes (1.42.0-wmf.25; 2024-04-02), Patch-For-Review, MW-1.41-notes (1.41.0-wmf.28; 2023-09-26), Wikimedia-Performance-recommendation, Wikimedia-Israel-Hackers, MediaWiki-extensions-Gadgets

Sun, Jun 23

Od1n added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

So (unless I'm mistaken), basically the rule is "RL may find the category if its wikicode tag exists in the currently displayed content". For instance:

Sun, Jun 23, 3:23 PM · MediaWiki-extensions-Gadgets

Sat, Jun 22

Pppery renamed T350104: Incorrect message when using standalone gadget definition pages from Incorrect message when using Gadget definition namespace to Incorrect message when using standalone gadget definition pages.
Sat, Jun 22, 4:03 PM · MediaWiki-extensions-Gadgets
Aklapper closed T234771: Localise Gadget aliases for ban as Declined.
Sat, Jun 22, 2:25 PM · I18n, MediaWiki-extensions-Gadgets

Fri, Jun 21

gerritbot added a comment to T367980: Expose gadgets metadata to lua.

Change #1047718 merged by jenkins-bot:

[integration/config@master] Add Scribunto as a phan dependency for Gadgets extension

https://gerrit.wikimedia.org/r/1047718

Fri, Jun 21, 2:06 PM · Patch-For-Review, MediaWiki-extensions-Gadgets

Thu, Jun 20

SD0001 added a comment to T349654: Allow gadgets to target change list pages .

This can be done now using the new categories option. The interface messages on top of change list pages (watchlist-summary, recentchanges-summary, recentchangeslinked-summary, histlegend) can be customised to include the category.

Thu, Jun 20, 9:13 AM · MediaWiki-extensions-Gadgets
gerritbot added a comment to T367980: Expose gadgets metadata to lua.

Change #1047718 had a related patch set uploaded (by SD0001; author: SD0001):

[integration/config@master] Add Scribunto as a phan dependency for Gadgets extension

https://gerrit.wikimedia.org/r/1047718

Thu, Jun 20, 5:55 AM · Patch-For-Review, MediaWiki-extensions-Gadgets

Wed, Jun 19

gerritbot added a project to T367980: Expose gadgets metadata to lua: Patch-For-Review.
Wed, Jun 19, 9:00 PM · Patch-For-Review, MediaWiki-extensions-Gadgets
gerritbot added a comment to T367980: Expose gadgets metadata to lua.

Change #1047603 had a related patch set uploaded (by SD0001; author: SD0001):

[mediawiki/extensions/Gadgets@master] Add lua library for retrieving gadgets metadata

https://gerrit.wikimedia.org/r/1047603

Wed, Jun 19, 8:59 PM · Patch-For-Review, MediaWiki-extensions-Gadgets
SD0001 created T367980: Expose gadgets metadata to lua.
Wed, Jun 19, 2:19 PM · Patch-For-Review, MediaWiki-extensions-Gadgets

Tue, Jun 11

SD0001 added a comment to T241524: Parser function for loading gadgets.

The cache purge probably just requires queueing a links update job with the right parameters; I think that would be the same with a parser function (which would presumably be tracked in the templatelinks table).

Tue, Jun 11, 9:33 AM · Patch-Needs-Improvement, MediaWiki-extensions-Gadgets
PerfektesChaos added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

Another issue: I have a case with a gadget ("Diaporama" here) that is defined with a "categories" condition, but this gadget may also be loaded using mw.loader.load()/ mw.loader.using() (by this script), on a page that does not have the category.

Tue, Jun 11, 9:24 AM · MediaWiki-extensions-Gadgets
SD0001 added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

Another issue: I have a case with a gadget ("Diaporama" here) that is defined with a "categories" condition, but this gadget may also be loaded using mw.loader.load()/ mw.loader.using() (by this script), on a page that does not have the category.

Tue, Jun 11, 9:09 AM · MediaWiki-extensions-Gadgets
Od1n added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

If you mean during preview, yes it will load if the last saved revision of the page had the category wikicode. What section you're editing is irrelevant.

Tue, Jun 11, 12:36 AM · MediaWiki-extensions-Gadgets
Od1n added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

Another issue: I have a case with a gadget that is defined with a "category" condition, but this gadget may also be loaded using mw.loader.load()/ mw.loader.using(), on pages that do not have the category.

Tue, Jun 11, 12:26 AM · MediaWiki-extensions-Gadgets

Sun, Jun 9

Tgr added a comment to T241524: Parser function for loading gadgets.

Most of those issues could probably be fixed by using the ContentAlterParserOutput hook instead of BeforePageDisplay, to detect the relevant categories and add the gadgets to the parser output.

Sun, Jun 9, 3:19 PM · Patch-Needs-Improvement, MediaWiki-extensions-Gadgets
SD0001 added a comment to T241524: Parser function for loading gadgets.

I don't think this should be closed just yet. This is still the "more correct" approach. The categories stuff is just a hack to avoid introducing new wikitext.

Sun, Jun 9, 2:12 PM · Patch-Needs-Improvement, MediaWiki-extensions-Gadgets
SD0001 added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

About the conditional loading based on categories: If we edit a section (instead of the entire page) and the category wikicode is outside the section, will the gadget be loaded, or not?

Sun, Jun 9, 2:09 PM · MediaWiki-extensions-Gadgets
Escargot_rouge added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

The category detection does not work when using quick preview and visual editor.
tested on fr:Moulinet_(échecs), Diaporama gadget works fine in all cases but these two

Sun, Jun 9, 12:36 PM · MediaWiki-extensions-Gadgets

Jun 6 2024

Od1n added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

Similarly, if the action if a history view, will the page categories be known?

Jun 6 2024, 1:28 PM · MediaWiki-extensions-Gadgets

Jun 4 2024

Od1n added a comment to T204201: Extend MediaWiki:Gadgets-definition capabilities.

About the conditional loading based on categories: If we edit a section (instead of the entire page) and the category wikicode is outside the section, will the gadget be loaded, or not?

Jun 4 2024, 6:44 PM · MediaWiki-extensions-Gadgets

Jun 2 2024

Pppery added a project to T328207: Change Namespace Aliases on diq.wikipedia: Language-Technical Support.
Jun 2 2024, 1:43 AM · LPL Technical Support, Scribunto, MediaWiki-Internationalization, Wikimedia-Site-requests
Pppery added a project to T327449: Update of namespace designations for Slovenian (sl) in MediaWiki: Language-Technical Support.
Jun 2 2024, 1:42 AM · LPL Technical Support, MW-1.41-notes (1.41.0-wmf.10; 2023-05-23), MediaWiki-Internationalization, Wikimedia-Site-requests

May 31 2024

SD0001 added a comment to T356509: Images/videos of gadgets should be shown next to gadgets in the Gadgets section of your preferences.

This should already be possible. The gadget description messages which are used in preferences support full wikitext.

May 31 2024, 6:34 PM · MediaWiki-extensions-Gadgets

May 26 2024

SD0001 added a comment to T357197: Allow ES8 (ES2017) code in gadgets.

You can't make that call with a broad brush like "all of MediaWiki" (or rather, you can only do so extremely conservatively), but when we're talking Gadgets we're inherently at a level of granularity where the community not only can, but is actually best situated to make calls like that.

A granularity that however runs inside the same execution pathways of mediawiki, and thus mixes in with all the other code. It is cool you want to do some redecorating, but we are living in the same house. If you poke a hole in the roof, the whole house has a leak, not just your room.

May 26 2024, 11:38 AM · MediaWiki-Platform-Team (Radar), MediaWiki-extensions-Gadgets
Xover added a comment to T357197: Allow ES8 (ES2017) code in gadgets.

Like I get the desire, but you also have to look at the impact of that desire for others.

May 26 2024, 10:19 AM · MediaWiki-Platform-Team (Radar), MediaWiki-extensions-Gadgets
TheDJ added a comment to T357197: Allow ES8 (ES2017) code in gadgets.

You can't make that call with a broad brush like "all of MediaWiki" (or rather, you can only do so extremely conservatively), but when we're talking Gadgets we're inherently at a level of granularity where the community not only can, but is actually best situated to make calls like that.

May 26 2024, 9:12 AM · MediaWiki-Platform-Team (Radar), MediaWiki-extensions-Gadgets
Xover added a comment to T357197: Allow ES8 (ES2017) code in gadgets.

[…]

May 26 2024, 8:25 AM · MediaWiki-Platform-Team (Radar), MediaWiki-extensions-Gadgets

May 23 2024

Jdlrobson added a comment to T361927: Allow specifying interface messages to load in gadget definitions.

Big +1 for this I've now hit this issue on two important widely used gadget efforts and have had to resort to creating my own i18n solution or hardcoding strings in a certain language which is not ideal :/

May 23 2024, 3:44 PM · I18n, MediaWiki-extensions-Gadgets

May 22 2024

Jdlrobson moved T360234: GadgetUsage should guide interface admins better in how they can contribute to better site performance from Improve how sites load on-wiki scripts to Future Unplanned on the Web-Team-Backlog (Needs Prioritization (Tech)) board.
May 22 2024, 7:11 PM · Web-Team-Backlog (Needs Prioritization (Tech)), MediaWiki-extensions-Gadgets

May 16 2024

Aklapper placed T65532: Gadget preferences should hide or discourage entries that can't be enabled in the current skin (e.g. vector-only) up for grabs.

@Majr: Removing task assignee as this open task has been assigned for more than two years - see the email sent to all task assignees on 2024-04-15.
Please assign this task to yourself again if you still realistically [plan to] work on this task - it would be welcome! :)
If this task has been resolved in the meantime, or should not be worked on by anybody ("declined"), please update its task status via "Add Action… 🡒 Change Status".
Also see https://www.mediawiki.org/wiki/Bug_management/Assignee_cleanup for tips how to best manage your individual work in Phabricator. Thanks!

May 16 2024, 5:10 PM · Patch-Needs-Improvement, MediaWiki-extensions-Gadgets
Aklapper placed T262493: Strategy for avoiding or excluding client side errors from gadgets and user scripts up for grabs.

@Jdlrobson: Removing task assignee as this open task has been assigned for more than two years - see the email sent to all task assignees on 2024-04-15.
Please assign this task to yourself again if you still realistically [plan to] work on this task - it would be welcome! :)
If this task has been resolved in the meantime, or should not be worked on by anybody ("declined"), please update its task status via "Add Action… 🡒 Change Status".
Also see https://www.mediawiki.org/wiki/Bug_management/Assignee_cleanup for tips how to best manage your individual work in Phabricator. Thanks!

May 16 2024, 5:07 PM · Instrument-ClientError, tech-decision-forum, EventStreams, MediaWiki-extensions-Gadgets
Aklapper placed T36958: User-level gadgets (aka "Gadgets 3.0") up for grabs.

@SD0001: Removing task assignee as this open task has been assigned for more than two years - see the email sent to all task assignees on 2024-04-15.
Please assign this task to yourself again if you still realistically [plan to] work on this task - it would be welcome! :)
If this task has been resolved in the meantime, or should not be worked on by anybody ("declined"), please update its task status via "Add Action… 🡒 Change Status".
Also see https://www.mediawiki.org/wiki/Bug_management/Assignee_cleanup for tips how to best manage your individual work in Phabricator. Thanks!

May 16 2024, 4:55 PM · Patch-Needs-Improvement, MediaWiki-Platform-Team (Radar), SecTeam-Processed, Security-Team, MediaWiki-ResourceLoader, Proposal, MediaWiki-extensions-Gadgets, JavaScript

May 4 2024

Tacsipacsi added a comment to T236603: Only register gadgets client-side from startup if relevant for the current skin.

I was wondering today why on earth a gadget defined on MediaWiki:Gadgets-definition cannot be loaded using mw.loader.load(). This should have been documented on mediawiki.org; better late than never.

May 4 2024, 12:14 PM · Wikimedia-Performance-publish, MW-1.39-notes (1.39.0-wmf.5; 2022-03-28), User-TheDJ, MediaWiki-extensions-Gadgets, Performance-Team (Radar)

May 3 2024

Maintenance_bot removed a project from T31272: Implement Gadgets 2.0: Patch-For-Review.
May 3 2024, 8:31 PM · MW-1.43-notes (1.43.0-wmf.4; 2024-05-07), User-notice, Gadgets-2.0, MediaWiki-extensions-Gadgets
ReleaseTaggerBot added a project to T31272: Implement Gadgets 2.0: MW-1.43-notes (1.43.0-wmf.4; 2024-05-07).
May 3 2024, 8:00 PM · MW-1.43-notes (1.43.0-wmf.4; 2024-05-07), User-notice, Gadgets-2.0, MediaWiki-extensions-Gadgets
gerritbot added a comment to T31272: Implement Gadgets 2.0.

Change #1014636 merged by jenkins-bot:

[mediawiki/extensions/Gadgets@master] Replace EditFilterMergedContent hook with ContentHandler override

https://gerrit.wikimedia.org/r/1014636

May 3 2024, 7:51 PM · MW-1.43-notes (1.43.0-wmf.4; 2024-05-07), User-notice, Gadgets-2.0, MediaWiki-extensions-Gadgets

Apr 29 2024

Pppery removed a project from T22153: Implement global gadgets (WMF-wide): MediaWiki-extensions-Interwiki.
Apr 29 2024, 5:07 AM · Gadgets-2.0, Developer-Advocacy, Epic, MediaWiki-extensions-Gadgets

Apr 24 2024

Jdlrobson triaged T360234: GadgetUsage should guide interface admins better in how they can contribute to better site performance as Medium priority.
Apr 24 2024, 3:15 PM · Web-Team-Backlog (Needs Prioritization (Tech)), MediaWiki-extensions-Gadgets
Tgr removed a project from T187749: Make it possible to use code from an external repository for editor-controlled Javascript/CSS: MediaWiki-core-Hackathon-2024.

I don't think there are hackathon-sized improvements to MediaWiki core specifically that would help here.

Apr 24 2024, 2:59 PM · Patch-Needs-Improvement, Security, Security-Team, Wikimedia-Hackathon-2019, Wikimedia-Hackathon-2018, MediaWiki-extension-requests, User-Tgr, JavaScript, MediaWiki-extensions-Gadgets

Apr 23 2024

larissagaulia added a project to T187749: Make it possible to use code from an external repository for editor-controlled Javascript/CSS: MediaWiki-core-Hackathon-2024.
Apr 23 2024, 1:50 PM · Patch-Needs-Improvement, Security, Security-Team, Wikimedia-Hackathon-2019, Wikimedia-Hackathon-2018, MediaWiki-extension-requests, User-Tgr, JavaScript, MediaWiki-extensions-Gadgets
PerfektesChaos added a comment to T110014: Make gadgets easily customizable (merge Gadgets' branch "gadgetprefs" from GSoC 2011).

How does this sound?

Some remarks:

  • This should not be a separate Special:GadgetPreferences but part of Special:Preferences in Gadgets section, when entire usage of one particular tool can be toggled. If this tool is activated, the preferences GUI should appear immediately below (and vanish if toggled off).
  • The JSON spec should be subpage like MediaWiki:Gadget-myTool/preferences.json, while site configuration might be MediaWiki:Gadget-myTool.json and implementation is at MediaWiki:Gadget-myTool.js
  • Texts do need localization mechanism. A global root may contain English, French, Japanese and German, and on Commons users will expect their user language. Further translations need to be added easily by global collection of local languages.
Apr 23 2024, 11:13 AM · MediaWiki-Core-Preferences, JavaScript, MediaWiki-extensions-Gadgets

Apr 22 2024

Krinkle closed T140323: Create reverse migration script for Gadgets 2.0 as Resolved.

With MultiGadgetRepo, adoption will be gradual with users having full autonomy at the individual gadget level. This means adopting a JSON gadget is as easy as creating the appropiate page (JSON will have precedence over the entry from the legacy definition page). And switching back would involve deleting or moving said page, or changing its content model, so as to not be loaded.

Apr 22 2024, 7:58 PM · MW-1.42-notes (1.42.0-wmf.21; 2024-03-05), MediaWiki-extensions-Gadgets, Community-Tech (2015-2017), Gadgets-2.0
Krinkle closed T140323: Create reverse migration script for Gadgets 2.0 , a subtask of T31398: Implement Gadget Manager, as Resolved.
Apr 22 2024, 7:56 PM · Patch-Needs-Improvement, Community-Tech (2015-2017), Gadgets-2.0, MediaWiki-extensions-Gadgets
Krinkle added a parent task for T31272: Implement Gadgets 2.0: T110014: Make gadgets easily customizable (merge Gadgets' branch "gadgetprefs" from GSoC 2011).
Apr 22 2024, 7:52 PM · MW-1.43-notes (1.43.0-wmf.4; 2024-05-07), User-notice, Gadgets-2.0, MediaWiki-extensions-Gadgets
Krinkle added a subtask for T110014: Make gadgets easily customizable (merge Gadgets' branch "gadgetprefs" from GSoC 2011): T31272: Implement Gadgets 2.0.
Apr 22 2024, 7:52 PM · MediaWiki-Core-Preferences, JavaScript, MediaWiki-extensions-Gadgets
Krinkle removed a subtask for T31272: Implement Gadgets 2.0: T110014: Make gadgets easily customizable (merge Gadgets' branch "gadgetprefs" from GSoC 2011).
Apr 22 2024, 7:52 PM · MW-1.43-notes (1.43.0-wmf.4; 2024-05-07), User-notice, Gadgets-2.0, MediaWiki-extensions-Gadgets