', + $changelog + ); + + $changelog = str_replace( + [ + '', + '[FREE]', + '[PRO]', + ], + [ + '', + 'FREE', + 'PRO', + ], + $changelog + ); + + $changelog = preg_replace( + '#\[J([1-9][\.0-9]*)\]#', + 'J\1', + $changelog + ); + + $title = 'Latest changes for ' . JText::_($this->name); + + if ($this->previous_version_simple && version_compare($this->previous_version_simple, $this_version, '<')) + { + $title .= ' since v' . $this->previous_version_simple; + } + + if ($this->previous_version_simple + && $this->getMajorVersionPart($this->previous_version_simple) < $this->getMajorVersionPart($this_version) + && ! $this->hasMessagesOfType('warning') + ) + { + JFactory::getApplication()->enqueueMessage(JText::sprintf('RLI_MAJOR_UPGRADE', JText::_($this->name)), 'warning'); + } + + return '' . $title . ':
' + . '' + . $changelog + . ''; + } +} diff --git a/src/structure/plugins/system/kickyootheme/kickyootheme.php b/src/structure/plugins/system/kickyootheme/kickyootheme.php new file mode 100644 index 0000000..974cc8e --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/kickyootheme.php @@ -0,0 +1,40 @@ + + * @author Stefan Wendhausen+ * @copyright Copyright © 2020 Kicktemp GmbH. All rights reserved. + * @license GNU General Public License version 3 or later; see LICENSE.txt + * @link https://kicktemp.com + */ + +defined('_JEXEC') or die; + +use function YOOtheme\app; +use YOOtheme\ImageProvider; + +/** + * Plugin class to modify the JDocumentHTML object + * + * @since 3.1 + */ +class plgSystemKickYOOtheme extends JPlugin +{ + protected $app; + + protected $buffer; + + public function onBeforeRender() + { + if (!$this->app->isClient('site')) + { + return false; + } + + $imageProvider = app(ImageProvider::class); + $content = JFactory::getDocument()->getBuffer('component'); + + JFactory::getDocument()->setBuffer($imageProvider->replace($content), 'component'); + } +} diff --git a/src/structure/plugins/system/kickyootheme/kickyootheme.xml b/src/structure/plugins/system/kickyootheme/kickyootheme.xml new file mode 100644 index 0000000..e2d166e --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/kickyootheme.xml @@ -0,0 +1,30 @@ + + + diff --git a/src/structure/plugins/system/kickyootheme/language/de-DE/de-DE.plg_system_kickyootheme.ini b/src/structure/plugins/system/kickyootheme/language/de-DE/de-DE.plg_system_kickyootheme.ini new file mode 100644 index 0000000..2a93c67 --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/language/de-DE/de-DE.plg_system_kickyootheme.ini @@ -0,0 +1,3 @@ +PLG_SYSTEM_KICKYOOTHEME="System - Kick YOOtheme Pro ImageProvider" +PLG_SYSTEM_KICKYOOTHEME_XML_DESCRIPTION="System plugin to modify the Component" +KICKDONATION="Projekt unterstützen?" diff --git a/src/structure/plugins/system/kickyootheme/language/de-DE/de-DE.plg_system_kickyootheme.sys.ini b/src/structure/plugins/system/kickyootheme/language/de-DE/de-DE.plg_system_kickyootheme.sys.ini new file mode 100644 index 0000000..88b730d --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/language/de-DE/de-DE.plg_system_kickyootheme.sys.ini @@ -0,0 +1,2 @@ +PLG_SYSTEM_KICKYOOTHEME="System - Kick YOOtheme Pro ImageProvider" +PLG_SYSTEM_KICKYOOTHEME_XML_DESCRIPTION="System plugin to modify the Component" diff --git a/src/structure/plugins/system/kickyootheme/language/en-GB/en-GB.plg_system_kickyootheme.ini b/src/structure/plugins/system/kickyootheme/language/en-GB/en-GB.plg_system_kickyootheme.ini new file mode 100644 index 0000000..2a93c67 --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/language/en-GB/en-GB.plg_system_kickyootheme.ini @@ -0,0 +1,3 @@ +PLG_SYSTEM_KICKYOOTHEME="System - Kick YOOtheme Pro ImageProvider" +PLG_SYSTEM_KICKYOOTHEME_XML_DESCRIPTION="System plugin to modify the Component" +KICKDONATION="Projekt unterstützen?" diff --git a/src/structure/plugins/system/kickyootheme/language/en-GB/en-GB.plg_system_kickyootheme.sys.ini b/src/structure/plugins/system/kickyootheme/language/en-GB/en-GB.plg_system_kickyootheme.sys.ini new file mode 100644 index 0000000..88b730d --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/language/en-GB/en-GB.plg_system_kickyootheme.sys.ini @@ -0,0 +1,2 @@ +PLG_SYSTEM_KICKYOOTHEME="System - Kick YOOtheme Pro ImageProvider" +PLG_SYSTEM_KICKYOOTHEME_XML_DESCRIPTION="System plugin to modify the Component" diff --git a/src/structure/plugins/system/kickyootheme/script.php b/src/structure/plugins/system/kickyootheme/script.php new file mode 100644 index 0000000..38c4729 --- /dev/null +++ b/src/structure/plugins/system/kickyootheme/script.php @@ -0,0 +1,30 @@ + + * @author Stefan Wendhausenplg_system_kickyootheme +Kicktemp GmbH +30 September 2019 +Copyright © 2019 Kicktemp GmbH. All rights reserved. +GNU General Public License version 3 or later; see LICENSE.txt +hello@kicktemp.com +https://kicktemp.com +@@VERSION +PLG_SYSTEM_KICKYOOTHEME_XML_DESCRIPTION ++ +language +fields +kickyootheme.php +kickscript.php ++ ++ + ++ ++ https://update.kicktemp.com/joomla/plugins/plg_system_kickyootheme/update.xml + ++ * @copyright Copyright © 2019 Kicktemp GmbH. All rights reserved. + * @license GNU General Public License version 3 or later; see LICENSE.txt + * @link https://kicktemp.com + */ + +/** + * Installation class to perform additional changes during install/uninstall/update + * + * @since 1.0 + */ +class PlgSystemKickYOOthemeScript extends JInstallerScript +{ + /** + * Extension script constructor. + * + * @since 1.0 + */ + public function __construct() + { + // Define the minumum versions to be supported. + $this->minimumJoomla = '3.8'; + $this->minimumPhp = '7.0'; + } +}