File defining hooks related to magic words.
More...
|
| getRepoName ( $lang) |
| Gets the user-facing repository name.
|
|
File defining hooks related to magic words.
- Copyright
- GPL-2.0-or-later
◆ __construct()
Wikibase\Client\Hooks\MagicWordHookHandler::__construct |
( |
SettingsArray | $settings | ) |
|
◆ getRepoName()
Wikibase\Client\Hooks\MagicWordHookHandler::getRepoName |
( |
| $lang | ) |
|
|
protected |
Gets the user-facing repository name.
This can either be a message's text, or the raw value from settings if that is not a message
- Parameters
-
Language | string | $lang | Language (code) to get text in |
- Returns
- string
◆ onMagicWordwgVariableIDs()
Wikibase\Client\Hooks\MagicWordHookHandler::onMagicWordwgVariableIDs |
( |
& | $aCustomVariableIds | ) |
|
Register all magic words.
- Parameters
-
string[] | &$aCustomVariableIds | |
- Returns
- bool
◆ onParserGetVariableValueSwitch()
Wikibase\Client\Hooks\MagicWordHookHandler::onParserGetVariableValueSwitch |
( |
| $parser, |
|
|
& | $cache, |
|
|
| $magicWordId, |
|
|
& | $ret, |
|
|
| $frame ) |
Handler for the ParserGetVariableValueSwitch hook.
Apply the magic word.
- Parameters
-
Parser | $parser | |
string[] | &$cache | |
string | $magicWordId | |
?string | &$ret | |
PPFrame | $frame | |
◆ onResourceLoaderJqueryMsgModuleMagicWords()
Wikibase\Client\Hooks\MagicWordHookHandler::onResourceLoaderJqueryMsgModuleMagicWords |
( |
RL\Context | $context, |
|
|
array & | $magicWords ) |
Handler for the ResourceLoaderJqueryMsgModuleMagicWords hook.
Adds magic word constant(s) for use by jQueryMsg.
- Parameters
-
RL\Context | $context | |
string[] | &$magicWords | Associative array mapping all-caps magic words to string values |
◆ $settings
Wikibase\Client\Hooks\MagicWordHookHandler::$settings |
|
protected |
The documentation for this class was generated from the following file: