This functionality has existed since 2008, introduced in MediaWiki 1.6 with r13173 (2afce2e3f58), as requested in T4115. The primary use case for it was the checkboxes on Special:Undelete. This still exist today:
Since then, the feature has been:
- (2010) Ported to ResourceLoader as part of mw.util.init. (r75287 / c28ba5133).
- (2010) Factored out into its own module, as dependency of mediawiki.util, called from mw.util.init. (r75546 / e2e6fb563b)
- (2011) Decoupled from mw.util.init into a general mediawiki.page.ready module for initialisation code on page views. This made mediawik.util free of side-effects, per T28799. (r90605 / 95173d11f)
It is currently registered as its own module, but only ever used as part of mediawiki.page.ready. Per the concerns outlined at T202154 and Page load, this does not make sense as its own module bundle.
It is currently loaded on all page views, but page views are by definition also the very context it can never be used on given wikitext cannot generally create forms (exception being Inputbox which wasn't designed to be affected by this afaik, and also doesn't produce many checkboxes). It is only needed on Special:Undelete and perhaps a handful of other forms (to be decide).
It currently applies to any checkbox anywhere on the page. This might trigger unexpectedly. It should instead be opt-in. For example, with a class name on a containing element (form, fieldset, etc).
- Where does it currently apply?
- Where do we want this to apply?
- Make it part of mediawiki.htmlform (similar to autoinfuse and other misc form utilities)
- Remove as generic snippet, and inline it where needed , e.g. for Special:Undelete as part of mediawiki.special.undelete.
- Provide it as OOUI feature and offer only on OOUI-powered pages.
- Remove the feature entirely?