From 73b6ad733fd7c82cee23868aad330923c2bf2484 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Mar 2019 10:34:19 +0100 Subject: [PATCH] Make font awesome 5.7 used by default --- COPYRIGHT | 3 +-- htdocs/theme/eldy/global.inc.php | 5 +++-- htdocs/theme/eldy/img/fontawesome/README | 3 --- .../img/fontawesome/cash-register-solid.svg | 1 - .../theme/eldy/img/fontawesome/home-solid.svg | 1 - htdocs/theme/eldy/main_menu_fa_icons.inc.php | 4 ++-- htdocs/theme/md/main_menu_fa_icons.inc.php | 17 +++++++++++++++++ htdocs/theme/md/style.css.php | 9 +++++++-- 8 files changed, 30 insertions(+), 13 deletions(-) delete mode 100644 htdocs/theme/eldy/img/fontawesome/README delete mode 100644 htdocs/theme/eldy/img/fontawesome/cash-register-solid.svg delete mode 100644 htdocs/theme/eldy/img/fontawesome/home-solid.svg create mode 100644 htdocs/theme/md/main_menu_fa_icons.inc.php diff --git a/COPYRIGHT b/COPYRIGHT index 39fba1007c3..b4cc9752426 100644 --- a/COPYRIGHT +++ b/COPYRIGHT @@ -57,8 +57,7 @@ Image libraries: Octicons 8.1 MIT Yes Font libraries: -Fontawesome 4.7 ? Yes -Fontawesome 5.0 ? Yes +Fontawesome 5.7.2 Font Awesome Free licence Yes For licenses compatibility informations: diff --git a/htdocs/theme/eldy/global.inc.php b/htdocs/theme/eldy/global.inc.php index 4145e0e3632..1cbda302574 100644 --- a/htdocs/theme/eldy/global.inc.php +++ b/htdocs/theme/eldy/global.inc.php @@ -1621,16 +1621,17 @@ a.tmenuimage:hover{ // Img file not found if (! $found) { - print "/* A mainmenu entry was found but img file ".$val.".png not found (check /".$val."/img/".$val.".png), so we use a generic one */\n"; if (! defined('DISABLE_FONT_AWSOME') && empty($conf->global->MAIN_DISABLE_FONT_AWESOME_5)) { + print "/* A mainmenu entry was found but img file ".$val.".png not found (check /".$val."/img/".$val.".png), so we use a generic one */\n"; print 'div.mainmenu.'.$val.'::before { content: "\f249"; }'; } else { + print "/* A mainmenu entry was found but img file ".$val.".png not found (check /".$val."/img/".$val.".png), so we use a generic one */\n"; $url=dol_buildpath($path.'/theme/'.$theme.'/img/menus/generic'.(min($generic,4))."_over.png", 1); - print "div.mainmenu.generic".$generic." {\n"; + print "div.mainmenu.".$val." {\n"; print " background-image: url(".$url.");\n"; print "}\n"; } diff --git a/htdocs/theme/eldy/img/fontawesome/README b/htdocs/theme/eldy/img/fontawesome/README deleted file mode 100644 index bd5c51480b3..00000000000 --- a/htdocs/theme/eldy/img/fontawesome/README +++ /dev/null @@ -1,3 +0,0 @@ -there icons are licensed under the Creative Commons Attribution 4.0 International license https://fontawesome.com/license -Credit font Awesome - diff --git a/htdocs/theme/eldy/img/fontawesome/cash-register-solid.svg b/htdocs/theme/eldy/img/fontawesome/cash-register-solid.svg deleted file mode 100644 index 9de110c5903..00000000000 --- a/htdocs/theme/eldy/img/fontawesome/cash-register-solid.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/htdocs/theme/eldy/img/fontawesome/home-solid.svg b/htdocs/theme/eldy/img/fontawesome/home-solid.svg deleted file mode 100644 index c1c8559c03b..00000000000 --- a/htdocs/theme/eldy/img/fontawesome/home-solid.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/htdocs/theme/eldy/main_menu_fa_icons.inc.php b/htdocs/theme/eldy/main_menu_fa_icons.inc.php index d59b1c7d30f..94b02ea7323 100644 --- a/htdocs/theme/eldy/main_menu_fa_icons.inc.php +++ b/htdocs/theme/eldy/main_menu_fa_icons.inc.php @@ -59,8 +59,8 @@ div.mainmenu.cashdesk .tmenuimage { height: ; background-color: #; width: 100%; - -webkit-mask: url(./img/fontawesome/cash-register-solid.svg) no-repeat 50% 50%; /* for old webkit browser */ - mask: url(./img/fontawesome/cash-register-solid.svg) no-repeat 50% 50%; + -webkit-mask: url() no-repeat 50% 50%; /* for old webkit browser */ + mask: url() no-repeat 50% 50%; } diff --git a/htdocs/theme/md/main_menu_fa_icons.inc.php b/htdocs/theme/md/main_menu_fa_icons.inc.php new file mode 100644 index 00000000000..681c90c75ae --- /dev/null +++ b/htdocs/theme/md/main_menu_fa_icons.inc.php @@ -0,0 +1,17 @@ + +/*