mediawiki-skins-Vector/includes/Components/VectorComponentLanguageButton.php
Jon Robson bcb2a73ba1 Introduce UserLinks and LanguageButton components
Bug: T322089
Change-Id: I0bf504b2c9c129ef56c95c2370204ee20a41bd7a
2022-12-07 20:01:36 +00:00

25 lines
549 B
PHP

<?php
namespace MediaWiki\Skins\Vector\Components;
use MediaWiki\Skins\Vector\Hooks;
/**
* VectorComponentLanguageButton component
*/
class VectorComponentLanguageButton implements VectorComponent {
/**
* @inheritDoc
*/
public function getTemplateData(): array {
return [
'id' => 'p-lang-btn-sticky-header',
'class' => 'mw-interlanguage-selector',
'is-quiet' => true,
'tabindex' => '-1',
'html-vector-button-icon' => Hooks::makeIcon( 'wikimedia-language' ),
'event' => 'ui.dropdown-p-lang-btn-sticky-header'
];
}
}