mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue
synced 2024-11-24 22:25:27 +00:00
Merge "Add hook that allows suppression of the talk page overlay"
This commit is contained in:
commit
f21558f313
|
@ -484,6 +484,12 @@ class SkinMinerva extends SkinMustache {
|
|||
private function isTalkPageWithViewAction() {
|
||||
$title = $this->getTitle();
|
||||
|
||||
// Hook is @unstable and only for use by DiscussionTools. Do not use for any other purpose.
|
||||
$hookContainer = MediaWikiServices::getInstance()->getHookContainer();
|
||||
if ( !$hookContainer->run( 'MinervaNeueTalkPageOverlay', [ $title, $this->getOutput() ] ) ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return $title->isTalkPage() && Action::getActionName( $this->getContext() ) === "view";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue