From 2e5634e60f813eb04eb8fc784d055f7348ff16d7 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 27 Nov 2016 14:21:23 +0100 Subject: [PATCH] Fix responsive design --- htdocs/admin/modules.php | 50 +++++++++---------- .../core/tpl/admin_extrafields_view.tpl.php | 5 +- htdocs/theme/eldy/style.css.php | 6 ++- htdocs/theme/md/style.css.php | 8 ++- 4 files changed, 38 insertions(+), 31 deletions(-) diff --git a/htdocs/admin/modules.php b/htdocs/admin/modules.php index 93dd8ea8969..a7b3065658d 100644 --- a/htdocs/admin/modules.php +++ b/htdocs/admin/modules.php @@ -286,23 +286,10 @@ if ($mode==='expdev') print $langs->trans("ModuleFamilyExperimental")."
$h = 0; $categidx='common'; // Main -//if (! empty($categ[$categidx])) -//{ - $head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx; - $head[$h][1] = $langs->trans("AvailableModules"); - $head[$h][2] = 'common'; - $h++; -//} - -/*$categidx='expdev'; -if (! empty($categ[$categidx])) -{ - $categidx='expdev'; - $head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx; - $head[$h][1] = $form->textwithpicto($langs->trans("ModuleFamilyExperimental"), $langs->trans('DoNotUseInProduction'), 1, 'warning', '', 0, 3); - $head[$h][2] = 'expdev'; - $h++; -}*/ +$head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx; +$head[$h][1] = $langs->trans("AvailableModules"); +$head[$h][2] = 'common'; +$h++; $categidx='marketplace'; $head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx; @@ -314,18 +301,19 @@ $h++; print "
\n"; -dol_fiche_head($head, $mode, ''); - $var=true; if ($mode != 'marketplace') { + print '
'; if ($optioncss != '') print ''; print ''; print ''; print ''; + dol_fiche_head($head, $mode, ''); + $moreforfilter = ''; $moreforfilter.='
'; $moreforfilter.= $langs->trans('Keyword') . ': '; @@ -362,12 +350,17 @@ if ($mode != 'marketplace') print $hookmanager->resPrint; //print '
'; } + + //dol_fiche_end(); + + print '

'; + //print '



'; - print '



'; - + $moreforfilter=''; + // Show list of modules - - print ''."\n"; + print '
'; + print '
'."\n"; $oldfamily=''; @@ -766,9 +759,12 @@ if ($mode != 'marketplace') } print "
\n"; + print ''; } else { + dol_fiche_head($head, $mode, ''); + // Marketplace print "\n"; print "\n"; @@ -780,7 +776,7 @@ else $var=!$var; print "\n"; $url='https://www.dolistore.com'; - print ''; + print ''; print ''; print ''; print ''; @@ -788,18 +784,18 @@ else $var=!$var; print "\n"; $url='https://partners.dolibarr.org'; - print ''; + print ''; print ''; print ''; print ''; print "
'.$langs->trans("DoliStoreDesc").''.$url.'
'.$langs->trans("DoliPartnersDesc").''.$url.'
\n"; + + //dol_fiche_end(); } - dol_fiche_end(); - // Show warning about external users if ($mode != 'marketplace') print info_admin(showModulesExludedForExternal($modules))."\n"; diff --git a/htdocs/core/tpl/admin_extrafields_view.tpl.php b/htdocs/core/tpl/admin_extrafields_view.tpl.php index 6acc81f009f..d20184c70b4 100644 --- a/htdocs/core/tpl/admin_extrafields_view.tpl.php +++ b/htdocs/core/tpl/admin_extrafields_view.tpl.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2010-2016 Laurent Destailleur * Copyright (C) 2012 Regis Houssin * * This program is free software; you can redistribute it and/or modify @@ -33,6 +33,7 @@ print '
'; // Load attribute_label $extrafields->fetch_name_optionals_label($elementtype); +print '
'; print ""; print ''; @@ -68,6 +69,6 @@ foreach($extrafields->attribute_type as $key => $value) } print "
"; - +print '
'; ?> diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index 117f6718f42..6685b0cc745 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -631,6 +631,7 @@ div.myavailability { .titlefieldcreate { width: 20%; } .titlefield { width: 25%; } .titlefieldmiddle { width: 50%; } +.imgmaxwidth180 { max-width: 180px; } /* Force values for small screen 1400 */ @media only screen and (max-width: 1400px) @@ -990,6 +991,9 @@ img.photoref, div.photoref { width: 80px; object-fit: contain; } +img.fitcontain { + object-fit: contain; +} div.photoref { display:table-cell; vertical-align:middle; @@ -4514,7 +4518,7 @@ img.demothumb { } @media only screen and (max-width: 767px) { - .imgopensurveywizard { width:95%; height: auto; } + .imgopensurveywizard, .imgautosize { width:95%; height: auto; } #tooltip { position: absolute; diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php index 21ff3a03442..43e5398b13e 100644 --- a/htdocs/theme/md/style.css.php +++ b/htdocs/theme/md/style.css.php @@ -636,6 +636,8 @@ div.myavailability { .titlefieldcreate { width: 20%; } .titlefield { width: 25%; } .titlefieldmiddle { width: 50%; } +.imgmaxwidth180 { max-width: 180px; } + /* Force values for small screen 1400 */ @media only screen and (max-width: 1400px) @@ -1038,6 +1040,9 @@ img.photoref, div.photoref { width: 80px; object-fit: contain; } +img.fitcontain { + object-fit: contain; +} div.photoref { display:table-cell; vertical-align:middle; @@ -1051,6 +1056,7 @@ img.photorefnoborder { object-fit: contain; border: 1px solid #CCC; } + .underrefbanner { } .underbanner { @@ -4441,7 +4447,7 @@ img.demothumb { } @media only screen and (max-width: 767px) { - .imgopensurveywizard { width:95%; height: auto; } + .imgopensurveywizard, .imgautosize { width:95%; height: auto; } #tooltip { position: absolute;