summaryrefslogtreecommitdiff
path: root/Vote.php
diff options
context:
space:
mode:
Diffstat (limited to 'Vote.php')
-rw-r--r--Vote.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/Vote.php b/Vote.php
index f1fd043..4f74e15 100644
--- a/Vote.php
+++ b/Vote.php
@@ -235,6 +235,14 @@ class VoteHooks {
->addHeaderHtml('<h3>' . wfMessage('vote-add-your-vote')->inLanguage($parser->getTargetLanguage()) . '</h3>')
->addFooterHtml('<script type="application/json" data-votes>'. json_encode($votes) . '</script>');
+ // The MobileFrontend extension requires the mw-ui-button CSS class for
+ // buttons to look good. Xml::submitButton however only adds that CSS
+ // class when the global variable $wgUseMediaWikiUIEverywhere is set to
+ // true ... and MobileFrontend for some reason doesn't set that variable,
+ // so we just set it here ... ¯\_(ツ)_/¯
+ global $wgUseMediaWikiUIEverywhere;
+ $wgUseMediaWikiUIEverywhere = true;
+
$html = $form->getHTML(false);
// dirty hack to work around https://phabricator.wikimedia.org/T319216