mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups
synced 2024-11-15 03:34:03 +00:00
56d8a8df55
Change-Id: Ia38b468741bdfd5bab5bb34df79bf01d549498a9
35 lines
1 KiB
PHP
35 lines
1 KiB
PHP
<?php
|
|
|
|
use MediaWiki\Logger\LoggerFactory;
|
|
use MediaWiki\MediaWikiServices;
|
|
use Popups\PopupsContext;
|
|
use Popups\PopupsGadgetsIntegration;
|
|
|
|
/**
|
|
* @codeCoverageIgnore
|
|
*/
|
|
return [
|
|
'Popups.Config' => static function ( MediaWikiServices $services ) {
|
|
return $services->getService( 'ConfigFactory' )
|
|
->makeConfig( PopupsContext::EXTENSION_NAME );
|
|
},
|
|
'Popups.GadgetsIntegration' => static function ( MediaWikiServices $services ) {
|
|
return new PopupsGadgetsIntegration(
|
|
$services->getService( 'Popups.Config' ),
|
|
ExtensionRegistry::getInstance()
|
|
);
|
|
},
|
|
'Popups.Logger' => static function ( MediaWikiServices $services ) {
|
|
return LoggerFactory::getInstance( PopupsContext::LOGGER_CHANNEL );
|
|
},
|
|
'Popups.Context' => static function ( MediaWikiServices $services ) {
|
|
return new PopupsContext(
|
|
$services->getService( 'Popups.Config' ),
|
|
ExtensionRegistry::getInstance(),
|
|
$services->getService( 'Popups.GadgetsIntegration' ),
|
|
$services->getSpecialPageFactory(),
|
|
$services->getUserOptionsLookup()
|
|
);
|
|
}
|
|
];
|