MediaWiki  master
MediaWiki\Hook\PreferencesGetLayoutHook Interface Reference

This is a hook handler interface, see docs/Hooks.md. More...

Inheritance diagram for MediaWiki\Hook\PreferencesGetLayoutHook:

Public Member Functions

 onPreferencesGetLayout (&$useMobileLayout, $skinName, $skinProperties=[])
 Use the hook to check if the preferences will have a mobile or desktop layout. More...
 

Detailed Description

This is a hook handler interface, see docs/Hooks.md.

Use the hook name "PreferencesGetLayout" to register handlers implementing this interface.

Stability: stable
to implement

Definition at line 12 of file PreferencesGetLayoutHook.php.

Member Function Documentation

◆ onPreferencesGetLayout()

MediaWiki\Hook\PreferencesGetLayoutHook::onPreferencesGetLayout ( $useMobileLayout,
  $skinName,
  $skinProperties = [] 
)

Use the hook to check if the preferences will have a mobile or desktop layout.

Since
1.40
Parameters
bool&$useMobileLayouta boolean which will indicate whether to use a mobile layout or not
string$skinNamethe name of the skin being used
array$skinPropertiesan associative array that includes skin properties. A skin property could be one of the following:
  • isResponsive: Whether a skin can be responsive.
  • getVersion: Get the version of the skin. Is an empty array by default
Returns
bool|void True or no return value to continue or false to abort

Implemented in MediaWiki\HookContainer\HookRunner.


The documentation for this interface was generated from the following file: