Implement NamespaceInputWidget
authorBartosz Dziewoński <matma.rex@gmail.com>
Tue, 14 Jul 2015 20:30:06 +0000 (22:30 +0200)
committerBartosz Dziewoński <matma.rex@gmail.com>
Fri, 17 Jul 2015 13:33:59 +0000 (13:33 +0000)
commit2ac9e2a4327af2102c20df5d186fc62858f0f9ca
treef39f280e9a967a81b37fcc558af906383406f31d
parent1162636d5a5e9e9e701c68341fa2bdcbe7c94b54
Implement NamespaceInputWidget

* Add PHP version of NamespaceInputWidget, co-authored by Florian,
  which consists of a DropdownInputWidget offering a choice of
  namespaces and two CheckboxInputWidgets allowing to also match
  associated namespace (talk/content) or to invert the choice.
* Add an incomplete JS version of NamespaceInputWidget, which is only
  really functional when infused from the PHP version (it can't
  generate the dropdown by itself, for example). Implement some JS to
  improve the experience of selecting the "all namespaces" option in
  the dropdown (by disabling the checkboxes when this happens).
* Split off a 'mediawiki.widgets.styles' module, which has the basic
  styles for PHP widgets which are to be loaded in the head. Make
  OutputPage::enableOOUI() also add this module (which should stay
  reasonably small).
* Use the new widget in HTMLForm's HTMLSelectNamespace field. It can
  be seen in action on Special:LinkSearch, for example.

Co-Authored-By: Florian <florian.schmidt.welzow@t-online.de>
Co-Authored-By: Bartosz Dziewoński <matma.rex@gmail.com>
Change-Id: I5cbfa9d0f6a8641148ce476b7dbe65e9096b4485
autoload.php
includes/OutputPage.php
includes/htmlform/HTMLSelectNamespace.php
includes/widget/AUTHORS.txt
includes/widget/NamespaceInputWidget.php [new file with mode: 0644]
resources/Resources.php
resources/src/mediawiki.widgets/mw.widgets.NamespaceInputWidget.base.css [new file with mode: 0644]
resources/src/mediawiki.widgets/mw.widgets.NamespaceInputWidget.js [new file with mode: 0644]