Skip to content

Commit

Permalink
v1.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
hiteshaggarwal committed Feb 23, 2021
1 parent 7f3dd56 commit 9e602b8
Show file tree
Hide file tree
Showing 44 changed files with 225 additions and 3,644 deletions.
21 changes: 5 additions & 16 deletions html/com_content/article/default.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@
use Joomla\CMS\Router\Route;
use Joomla\CMS\Uri\Uri;

HTMLHelper::addIncludePath(JPATH_COMPONENT . '/helpers');

if (ASTROID_JOOMLA_VERSION > 3) {
\JLoader::registerAlias('ContentHelperRoute', 'Joomla\Component\Content\Site\Helper\RouteHelper');
} else {
Expand Down Expand Up @@ -67,12 +69,6 @@
<?php $useDefList = ($params->get('show_modify_date') || $params->get('show_publish_date') || $params->get('show_create_date') || $params->get('show_hits') || $params->get('show_category') || $params->get('show_parent_category') || $params->get('show_author') || $assocParam || $template->params->get('astroid_readtime', 1));
?>

<?php if (!$useDefList && $this->print) : ?>
<div id="pop-print" class="btn hidden-print">
<?php echo HTMLHelper::_('icon.print_screen', $this->item, $params); ?>
</div>
<div class="clearfix"> </div>
<?php endif; ?>
<?php $astroidArticle->render('above-title'); ?>
<?php if (($params->get('show_title') || $params->get('show_author'))) : ?>
<div class="item-title">
Expand All @@ -95,16 +91,9 @@
<?php endif; ?>
</div>
<?php endif; ?>
<?php if (!$this->print) : ?>
<?php if ($canEdit || $params->get('show_print_icon') || $params->get('show_email_icon')) : ?>
<?php echo LayoutHelper::render('joomla.content.icons', array('params' => $params, 'item' => $this->item, 'print' => false)); ?>
<?php endif; ?>
<?php else : ?>
<?php if ($useDefList) : ?>
<div id="pop-print" class="btn hidden-print">
<?php echo HTMLHelper::_('icon.print_screen', $this->item, $params); ?>
</div>
<?php endif; ?>

<?php if ($canEdit) : ?>
<?php echo LayoutHelper::render('joomla.content.icons', array('params' => $params, 'item' => $this->item)); ?>
<?php endif; ?>

<?php // Content is generated by content plugin event "onContentAfterTitle"
Expand Down
252 changes: 0 additions & 252 deletions html/com_content/form/edit.php

This file was deleted.

55 changes: 14 additions & 41 deletions html/layouts/joomla/content/icons.php
Original file line number Diff line number Diff line change
@@ -1,54 +1,27 @@
<?php

/**
* @package Astroid Framework
* @author JoomDev https://www.joomdev.com
* @copyright Copyright (C) 2009 - 2020 JoomDev.
* @license https://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or Later
* @package Joomla.Site
* @subpackage Layout
*
* @copyright (C) 2013 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;
defined('_JEXEC') or die;

use Joomla\CMS\HTML\HTMLHelper;
use Joomla\CMS\Language\Text;

HTMLHelper::_('bootstrap.framework');

$canEdit = $displayData['params']->get('access-edit');
$canEdit = $displayData['params']->get('access-edit');
$articleId = $displayData['item']->id;

?>

<div class="icons">
<?php if (empty($displayData['print'])) : ?>

<?php if ($canEdit || $displayData['params']->get('show_print_icon') || $displayData['params']->get('show_email_icon')) : ?>
<div class="btn-group content-edit-dropdown float-right">
<button class="btn dropdown-toggle py-1 px-2" type="button" id="dropdownMenuButton-<?php echo $articleId; ?>" aria-label="<?php echo Text::_('JUSER_TOOLS'); ?>" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
<span class="fas fa-cog fa-sm" aria-hidden="true"></span>
<span class="caret" aria-hidden="true"></span>
</button>
<?php // Note the actions class is deprecated. Use dropdown-menu instead.
?>
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton-<?php echo $articleId; ?>">
<?php if ($displayData['params']->get('show_print_icon')) : ?>
<li class="dropdown-item print-icon"> <?php echo HTMLHelper::_('icon.print_popup', $displayData['item'], $displayData['params']); ?> </li>
<?php endif; ?>
<?php if ($displayData['params']->get('show_email_icon')) : ?>
<li class="dropdown-item email-icon"> <?php echo HTMLHelper::_('icon.email', $displayData['item'], $displayData['params']); ?> </li>
<?php endif; ?>
<?php if ($canEdit) : ?>
<li class="dropdown-item edit-icon"> <?php echo HTMLHelper::_('icon.edit', $displayData['item'], $displayData['params']); ?> </li>
<?php endif; ?>
</div>
</div>
<?php endif; ?>

<?php else : ?>

<?php if ($canEdit) : ?>
<div class="icons">
<div class="float-right">
<?php echo HTMLHelper::_('icon.print_screen', $displayData['item'], $displayData['params']); ?>
<div>
<?php echo HTMLHelper::_('icon.edit', $displayData['item'], $displayData['params']); ?>
</div>
</div>

<?php endif; ?>
</div>
</div>
<?php endif; ?>
16 changes: 4 additions & 12 deletions html/layouts/joomla/content/icons/create.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,20 @@
* @package Joomla.Site
* @subpackage Layout
*
* @copyright Copyright (C) 2005 - 2019 Open Source Matters, Inc. All rights reserved.
* @copyright (C) 2016 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('JPATH_BASE') or die;
defined('_JEXEC') or die;

use Joomla\CMS\HTML\HTMLHelper;
use Joomla\CMS\Language\Text;

HTMLHelper::_('bootstrap.tooltip');

$params = $displayData['params'];
$legacy = $displayData['legacy'];

?>
<?php if ($params->get('show_icons')) : ?>
<?php if ($legacy) : ?>
<?php echo HTMLHelper::_('image', 'system/new.png', Text::_('JNEW'), null, true); ?>
<?php else : ?>
<span class="icon-plus" aria-hidden="true"></span>
<?php echo Text::_('JNEW'); ?>
<?php endif; ?>
<span class="fas fa-plus" aria-hidden="true"></span>
<?php echo Text::_('JNEW'); ?>
<?php else : ?>
<?php echo Text::_('JNEW') . '&#160;'; ?>
<?php endif; ?>
Loading

0 comments on commit 9e602b8

Please sign in to comment.