diff --git a/includes/CitizenTemplate.php b/includes/CitizenTemplate.php index 3c36b3f6..33cb0ac5 100644 --- a/includes/CitizenTemplate.php +++ b/includes/CitizenTemplate.php @@ -4,7 +4,6 @@ use MediaWiki\MediaWikiServices; /** * BaseTemplate class for the Citizen skin - * TODO: Add missing title to buttons * @ingroup Skins */ class CitizenTemplate extends BaseTemplate { @@ -123,6 +122,7 @@ class CitizenTemplate extends BaseTemplate { /** * Render the navigation menu + * TODO: Convert the rest to Mustache * @return array */ private function buildMenu() : array { @@ -210,40 +210,6 @@ class CitizenTemplate extends BaseTemplate { return $props; } - /** - * Generates the sitetitle - * @param string $option - * @return string html - */ - protected function getSiteTitle( $option ) { - $html = ''; - $language = $this->getSkin()->getLanguage(); - $siteTitle = $language->convert( $this->getMsg( 'sitetitle' )->escaped() ); - - if ( $option === 'link' ) { - $html .= Html::rawElement( - 'a', - [ - 'id' => 'p-banner', - 'class' => 'mw-wiki-title', - 'href' => $this->data['nav_urls']['mainpage']['href'], - ] + Linker::tooltipAndAccesskeyAttribs( 'p-logo' ), - $siteTitle - ); - } elseif ( $option === 'text' ) { - $html .= Html::rawElement( - 'span', - [ - 'id' => 'p-banner', - 'class' => 'mw-wiki-title', - ], - $siteTitle - ); - } - - return $html; - } - /** * Generates the sidebar * Set the elements to true to allow them to be part of the sidebar @@ -259,7 +225,6 @@ class CitizenTemplate extends BaseTemplate { $sidebar = $this->getSidebar(); $sidebar['TOOLBOX'] = true; - $sidebar['LANGUAGES'] = false; foreach ( $sidebar as $name => $content ) { if ( $content === false ) { @@ -272,9 +237,6 @@ class CitizenTemplate extends BaseTemplate { case 'TOOLBOX': $html .= $this->getPortlet( 'tb', $this->getToolbox(), 'toolbox' ); break; - case 'LANGUAGES': - $html .= $this->getLanguageLinks(); - break; default: $html .= $this->getPortlet( $name, $content['content'] ); break; @@ -344,20 +306,6 @@ class CitizenTemplate extends BaseTemplate { return $html . Html::closeElement( 'div' ); } - /** - * In other languages list - * - * @return string html - */ - protected function getLanguageLinks() { - $html = ''; - if ( $this->data['language_urls'] !== false ) { - $html .= $this->getPortlet( 'lang', $this->data['language_urls'], 'otherlanguages' ); - } - - return $html; - } - /** * Language variants. Displays list for converting between different scripts in the same language, * if using a language where this is applicable (such as latin vs cyric display for serbian).