00d44256b4
Rebrand all 17 sub-extensions from mokowaas to mokosuite naming, including component, plugins, modules, task plugins, and webservices. Updates package manifest, workflows, docs, wiki, and issue templates. Adds new plg_system_mokosuite_license extension.
39 lines
1.2 KiB
PHP
39 lines
1.2 KiB
PHP
<?php
|
|
/**
|
|
* @package MokoSuite
|
|
* @subpackage com_mokosuite
|
|
* @copyright Copyright (C) 2026 Moko Consulting. All rights reserved.
|
|
* @license GNU General Public License version 3 or later; see LICENSE
|
|
*/
|
|
|
|
defined('_JEXEC') or die;
|
|
|
|
use Joomla\CMS\Dispatcher\ComponentDispatcherFactoryInterface;
|
|
use Joomla\CMS\Extension\ComponentInterface;
|
|
use Joomla\CMS\Extension\Service\Provider\ComponentDispatcherFactory;
|
|
use Joomla\CMS\Extension\Service\Provider\MVCFactory;
|
|
use Joomla\CMS\MVC\Factory\MVCFactoryInterface;
|
|
use Joomla\DI\Container;
|
|
use Joomla\DI\ServiceProviderInterface;
|
|
|
|
return new class implements ServiceProviderInterface
|
|
{
|
|
public function register(Container $container): void
|
|
{
|
|
$container->registerServiceProvider(new MVCFactory('\\Moko\\Component\\MokoSuite'));
|
|
$container->registerServiceProvider(new ComponentDispatcherFactory('\\Moko\\Component\\MokoSuite'));
|
|
|
|
$container->set(
|
|
ComponentInterface::class,
|
|
function (Container $container) {
|
|
$component = new \Joomla\CMS\Extension\MVCComponent(
|
|
$container->get(ComponentDispatcherFactoryInterface::class)
|
|
);
|
|
$component->setMVCFactory($container->get(MVCFactoryInterface::class));
|
|
|
|
return $component;
|
|
}
|
|
);
|
|
}
|
|
};
|