- md5
- 3c75706988ca32314849669570db207f
- sha1
- eabb2579eb7673cbc11d542b2bdf3a4dda65342f
- sha256
- 472e3b92a1864befd561ab0289a945627d839ab29c2c920084edb398c9aae5cd
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
<?php
/**
* @package Joomla.Plugin
* @subpackage Media-Action.crop
*
* @copyright (C) 2017 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace Joomla\Plugin\MediaAction\Crop\Extension;
use Joomla\CMS\Application\CMSWebApplicationInterface;
use Joomla\Component\Media\Administrator\Plugin\MediaActionPlugin;
// phpcs:disable PSR1.Files.SideEffects
\defined('_JEXEC') or die;
// phpcs:enable PSR1.Files.SideEffects
/**
* Media Manager Crop Action
*
* @since 4.0.0
*/
final class Crop extends MediaActionPlugin
{
/**
* Load the javascript files of the plugin.
*
* @return void
*
* @since 4.0.0
*/
protected function loadJs()
{
parent::loadJs();
if (!$this->getApplication() instanceof CMSWebApplicationInterface) {
return;
}
$this->getApplication()->getDocument()->getWebAssetManager()->useScript('cropperjs');
}
/**
* Load the CSS files of the plugin.
*
* @return void
*
* @since 4.0.0
*/
protected function loadCss()
{
parent::loadCss();
if (!$this->getApplication() instanceof CMSWebApplicationInterface) {
return;
}
$this->getApplication()->getDocument()->getWebAssetManager()->useStyle('cropperjs');
}
}
The same content is in 38 releases, Joomla 4.4.0-alpha1 to 5.0.0-alpha1. See them all, or every version of this file.