Remove unnecessary class and attribute for icons

pull/4991/head
Angel Fernando Quiroz Campos 1 year ago
parent 024dc2a03a
commit c26774bb65
  1. 3
      public/main/inc/lib/display.lib.php
  2. 2
      public/main/inc/lib/document.lib.php
  3. 2
      src/CoreBundle/Resources/views/Admin/Settings/menu.html.twig
  4. 46
      src/CoreBundle/Resources/views/LearnPath/list.html.twig
  5. 6
      src/CoreBundle/Resources/views/LearnPath/menubar.html.twig
  6. 8
      src/CoreBundle/Resources/views/LearnPath/view.html.twig

@ -2227,9 +2227,8 @@ class Display
if (empty($style)) {
$style = '';
}
$additionalAttributes['class'] = "mdi-$name mdi v-icon notranslate v-icon--size-default $additionalClass";
$additionalAttributes['class'] = "mdi-$name mdi $additionalClass";
$additionalAttributes['style'] = $sizeString.$style;
$additionalAttributes['medium'] = '';
$additionalAttributes['aria-hidden'] = 'true';
if (!empty($title)) {

@ -2334,7 +2334,7 @@ class DocumentManager
$repo = Container::getDocumentRepository();
$nodeRepository = $repo->getResourceNodeRepository();
$move = get_lang('Move');
$icon = '<i class="mdi-cursor-move mdi v-icon ch-tool-icon" style="font-size: 16px; width: 16px; height: 16px;" aria-hidden="true" medium="" title="'.htmlentities(get_lang('Move')).'"></i>';
$icon = '<i class="mdi-cursor-move mdi ch-tool-icon" style="font-size: 16px; width: 16px; height: 16px;" aria-hidden="true" title="'.htmlentities(get_lang('Move')).'"></i>';
$folderIcon = Display::return_icon('lp_folder.png');
$options = [

@ -46,7 +46,7 @@
class="list-group-item border-0 {% if (current_namespace == namespace) %} bg-gray-25 rounded-lg {% endif %} "
href="{{ path('chamilo_platform_settings', { 'namespace': namespace }) }}"
>
<i class="mdi mdi-{{ array[namespace] }} ch-tool-icon-gradient" style="font-size: 32px; width: 32px; height: 32px; line-height: 32px;" aria-hidden="true" medium="" title="{{ namespace | capitalize | trans }}"></i>
<i class="mdi mdi-{{ array[namespace] }} ch-tool-icon-gradient" style="font-size: 32px; width: 32px; height: 32px; line-height: 32px;" aria-hidden="true" title="{{ namespace | capitalize | trans }}"></i>
{{ namespace | capitalize | trans }}
</a>

@ -36,35 +36,35 @@
{% if not session %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=add_lp_category&id=' ~ lp_data.category.iid }}"
title="{{ "Edit"|trans }}">
<i class="mdi-pencil mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Edit"|trans }}"></i>
<i class="mdi-pencil mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Edit"|trans }}"></i>
</a>
{% if subscription_settings.allow_add_users_to_lp_category %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=add_users_to_category&id=' ~ lp_data.category.iid }}"
title="{{ "Add users"|trans }}">
<i class="mdi-account-multiple-plus mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Add users"|trans }}"></i>
<i class="mdi-account-multiple-plus mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Add users"|trans }}"></i>
</a>
{% endif %}
{% if loop.index0 == 1 %}
<a href="#">
<i class="mdi-arrow-up-bold mdi v-icon ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-up-bold mdi ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% else %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=move_up_category&id=' ~ lp_data.category.iid }}"
title="{{ "Move"|trans }}">
<i class="mdi-arrow-up-bold mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-up-bold mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% endif %}
{% if (data|length - 1) == loop.index0 %}
<a href="#">
<i class="mdi-arrow-down-bold mdi v-icon ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-down-bold mdi ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% else %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=move_down_category&id=' ~ lp_data.category.iid }}"
title="{{ "Move"|trans }}">
<i class="mdi-arrow-down-bold mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-down-bold mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% endif %}
{% endif %}
@ -72,32 +72,32 @@
{% if lp_data.category_visibility == 0 %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_visibility', 'id':lp_data.category.iid, 'new_status':1}|url_encode }}"
title="{{ 'Show'|trans }}">
<i class="mdi-eye-off mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Show"|trans }}"></i>
<i class="mdi-eye-off mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Show"|trans }}"></i>
</a>
{% else %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_visibility', 'id':lp_data.category.iid, 'new_status':0}|url_encode }}"
title="{{ 'Hide'|trans }}">
<i class="mdi-eye mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Hide"|trans }}"></i>
<i class="mdi-eye mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Hide"|trans }}"></i>
</a>
{% endif %}
{% if lp_data.category_is_published == 0 %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_publish', 'id':lp_data.category.iid, 'new_status':1}|url_encode }}"
title="{{ 'LearnpathPublish'|trans }}">
<i class="mdi-checkbox-multiple-blank-outline mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "LearnpathPublish"|trans }}"></i>
<i class="mdi-checkbox-multiple-blank-outline mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "LearnpathPublish"|trans }}"></i>
</a>
{% else %}
<a
href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_publish', 'id':lp_data.category.iid, 'new_status':0}|url_encode }}"
title="{{ 'Do not publish'|trans }}"
>
<i class="mdi-checkbox-multiple-blank mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Hide"|trans }}"></i>
<i class="mdi-checkbox-multiple-blank mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Hide"|trans }}"></i>
</a>
{% endif %}
{% if not session %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=delete_lp_category&id=' ~ lp_data.category.iid }}"
title="{{ "Delete"|trans }}">
<i class="mdi-delete mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Delete"|trans }}"></i>
<i class="mdi-delete mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Delete"|trans }}"></i>
</a>
{% endif %}
{% endif %}
@ -351,35 +351,35 @@
{% if not session %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=add_lp_category&id=' ~ lp_data.category.iid }}"
title="{{ "Edit"|trans }}">
<i class="mdi-pencil mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Edit"|trans }}"></i>
<i class="mdi-pencil mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Edit"|trans }}"></i>
</a>
{% if subscription_settings.allow_add_users_to_lp_category %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=add_users_to_category&id=' ~ lp_data.category.iid }}"
title="{{ "Add users"|trans }}">
<i class="mdi-account-multiple-plus mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Add users"|trans }}"></i>
<i class="mdi-account-multiple-plus mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Add users"|trans }}"></i>
</a>
{% endif %}
{% if loop.index0 == 1 %}
<a href="#">
<i class="mdi-arrow-up-bold mdi v-icon ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-up-bold mdi ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% else %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=move_up_category&id=' ~ lp_data.category.iid }}"
title="{{ "Move"|trans }}">
<i class="mdi-arrow-up-bold mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-up-bold mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% endif %}
{% if (data|length - 1) == loop.index0 %}
<a href="#">
<i class="mdi-arrow-down-bold mdi v-icon ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-down-bold mdi ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% else %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=move_down_category&id=' ~ lp_data.category.iid }}"
title="{{ "Move"|trans }}">
<i class="mdi-arrow-down-bold mdi v-icon ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Move"|trans }}"></i>
<i class="mdi-arrow-down-bold mdi ch-tool-icon-disabled" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Move"|trans }}"></i>
</a>
{% endif %}
{% endif %}
@ -387,12 +387,12 @@
{% if lp_data.category_visibility == 0 %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_visibility', 'id':lp_data.category.iid, 'new_status':1}|url_encode }}"
title="{{ 'Show'|trans }}">
<i class="mdi-eye-off mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Show"|trans }}"></i>
<i class="mdi-eye-off mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Show"|trans }}"></i>
</a>
{% else %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_visibility', 'id':lp_data.category.iid, 'new_status':0}|url_encode }}"
title="{{ 'Hide'|trans }}">
<i class="mdi-eye mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Hide"|trans }}"></i>
<i class="mdi-eye mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Hide"|trans }}"></i>
</a>
{% endif %}
@ -400,22 +400,22 @@
{% if lp_data.category_is_published == 0 %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_publish', 'id':lp_data.category.iid, 'new_status':1}|url_encode }}"
title="{{ 'LearnpathPublish'|trans }}">
<i class="mdi-checkbox-multiple-blank-outline mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "LearnpathPublish"|trans }}"></i>
<i class="mdi-checkbox-multiple-blank-outline mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "LearnpathPublish"|trans }}"></i>
</a>
{% else %}
<a href="lp_controller.php?{{ course_url_params ~ '&' ~ {'action':'toggle_category_publish', 'id':lp_data.category.iid, 'new_status':0}|url_encode }}"
title="{{ 'LearnpathDoNotPublish'|trans }}">
<i class="mdi-checkbox-multiple-blank mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Hide"|trans }}"></i>
<i class="mdi-checkbox-multiple-blank mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Hide"|trans }}"></i>
</a>
{% endif %}
{% else %}
<i class="mdi-checkbox-multiple-blank-outline mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "LearnpathPublish"|trans }}"></i>
<i class="mdi-checkbox-multiple-blank-outline mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "LearnpathPublish"|trans }}"></i>
{% endif %}
{% if not session %}
<a href="{{ 'lp_controller.php?' ~ course_url_params ~ '&action=delete_lp_category&id=' ~ lp_data.category.iid }}"
title="{{ "Delete"|trans }}">
<i class="mdi-delete mdi v-icon ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" medium="" title="{{ "Delete"|trans }}"></i>
<i class="mdi-delete mdi ch-tool-icon" style="font-size: 22px; width: 22px; height: 22px;" aria-hidden="true" title="{{ "Delete"|trans }}"></i>
</a>
{% endif %}
{% endif %}

@ -24,7 +24,7 @@
role="button"
title="{{ label }}"
>
<i class="mdi-{{ icon_expand }} mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="mdi-{{ icon_expand }} mdi" aria-hidden="true"></i>
</a>
{% endif %}
<a id="home-course"
@ -32,13 +32,13 @@
href="{{ button_home_url }}"
class="icon-toolbar" target="_self"
onclick="javascript: window.parent.API.save_asset();">
<i class="mdi-home mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="mdi-home mdi" aria-hidden="true"></i>
</a>
{{ navigation_bar }}
</div>
<a title="{{ 'Options'|trans }}" class="menu-button icons" href="#">
<i class="mdi-menu mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="mdi-menu mdi" aria-hidden="true"></i>
</a>
</nav>
{% endautoescape %}

@ -113,13 +113,13 @@
<div class="col-xs-6">
{% if gamification_stars > 0 %}
{% for i in 1..gamification_stars %}
<i class="level mdi-star-face mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="level mdi-star-face mdi" aria-hidden="true"></i>
{% endfor %}
{% endif %}
{% if gamification_stars < 4 %}
{% for i in 1..4 - gamification_stars %}
<i class="mdi-home-outline mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="mdi-home-outline mdi" aria-hidden="true"></i>
{% endfor %}
{% endif %}
</div>
@ -168,14 +168,14 @@
<li role="presentation" class="active">
<a href="#lp-view-content" title="{{ 'Lesson'|trans }}"
aria-controls="lp-view-content" role="tab" data-toggle="tab">
<i class="mdi-book mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="mdi-book mdi" aria-hidden="true"></i>
<span class="sr-only">{{ 'Lesson'|trans }}</span>
</a>
</li>
<li role="presentation">
<a href="#lp-view-forum" title="{{ 'Forum'|trans }}"
aria-controls="lp-view-forum" role="tab" data-toggle="tab">
<i class="mdi-message-reply-text mdi v-icon notranslate v-icon--size-default" aria-hidden="true" medium=""></i>
<i class="mdi-message-reply-text mdi" aria-hidden="true"></i>
<span class="sr-only">{{ 'Forum'|trans }}</span>
</a>
</li>

Loading…
Cancel
Save