From 9dae99d4b62f883667bd595c40b6fae1e746f9ed Mon Sep 17 00:00:00 2001 From: Timothy Alexis Vass Date: Wed, 13 May 2020 11:02:44 +0200 Subject: [PATCH] Bug 25477: The responsive design in opac-main.tt should be correct @media (min-width:768px) and (max-width:979px): The layouts with columns are too narrow. This patch changes the layout to be span8+span4 and puts OpacNav/OpacNavBottom under Login/OpacNavRight in the right column. To test: 1) Navigate to cgi-bin/koha/opac-main.pl with content in OpacNav/OpacNavBottom and Login/OpacNavRight, or look at the attached screenshots: https://bugs.koha-community.org/bugzilla3/attachment.cgi?bugid=25477&action=viewall&hide_obsolete=1 2) Apply patch. 3) Try different screen widths at 678px and above. 4) Sign off. Sponsored-by: Lunds Universitetsbibliotek --- .../opac-tmpl/bootstrap/css/src/opac.scss | 4 + .../bootstrap/en/modules/opac-main.tt | 163 ++++++++++-------- 2 files changed, 93 insertions(+), 74 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss index 8babc17b63..86d1cf52b8 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss +++ b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss @@ -266,6 +266,10 @@ th { } } +#wrap { + padding: 0; +} + #advsearches, #booleansearch { label { diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt index e9b4e34616..92b867951e 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt @@ -25,7 +25,7 @@ - [% IF Koha.Preference( 'opacuserlogin' ) == 1 %] + [% IF ( Koha.Preference( 'opacuserlogin' ) == 1 ) %] [% IF ( loggedinusername ) %]
[% ELSE %] @@ -36,24 +36,36 @@ [% END %]
- [% IF ( OpacNav || OpacNavBottom ) %] -
- -
- [% END %] - - [% IF ( OpacNav || OpacNavBottom ) && (Koha.Preference( 'opacuserlogin' ) == 1 || OpacNavRight) %] -
- [% ELSIF (Koha.Preference( 'opacuserlogin' ) == 1 || OpacNavRight) %] -
- [% ELSIF ( OpacNav || OpacNavBottom ) %] -
+ [% IF ( OpacNav || OpacNavBottom || Koha.Preference( 'opacuserlogin' ) == 1 || OpacNavRight) %] +
[% ELSE %]
[% END %] - +

Welcome

+

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod + tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, + quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo + consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse + cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non + proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

+

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod + tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, + quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo + consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse + cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non + proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

+

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod + tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, + quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo + consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse + cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non + proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

+

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod + tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, + quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo + consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse + cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non + proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

[% IF Koha.Preference( 'OpacNewsLibrarySelect' ) %] [% UNLESS news_item %]
@@ -158,70 +170,73 @@ [% END %] [% END %] -
- - [% IF ( ( Koha.Preference( 'opacuserlogin' ) == 1 ) || OpacNavRight ) %] -
- [% IF Koha.Preference( 'opacuserlogin' ) == 1 %] - [% UNLESS ( loggedinusername ) %] - [% UNLESS ( casAuthentication || shibbolethAuthentication ) %] -
- - -
- Log in to your account: - - -
- -
- [% IF Koha.Preference( 'OpacLoginInstructions' ) %] -
- [% Koha.Preference( 'OpacLoginInstructions' ) | $raw %] -
- [% END %] - [% IF Koha.Preference('OpacPasswordChange') && Categories.can_any_reset_password %] - - [% END %] - [% IF PatronSelfRegistration && PatronSelfRegistrationDefaultCategory %] -
-

Don't have an account? Register here.

-
- [% END %] +
+ + [% IF ( OpacNav || OpacNavBottom || Koha.Preference( 'opacuserlogin' ) == 1 || OpacNavRight ) %] +
+ [% IF ( Koha.Preference( 'opacuserlogin' ) == 1 ) %] + [% UNLESS ( aloggedinusername ) %] + [% UNLESS ( bcasAuthentication || fshibbolethAuthentication ) %] +
+ + +
+ Log in to your account: + + +
+
- -
- [% END # /casAuthentication %] - [% ELSE %] - [% IF Koha.Preference('OPACUserSummary') && dashboard_info %] -
-

Welcome, [% INCLUDE 'patron-title.inc' patron = logged_in_user %]

- -
- [% END %] - [% END # /loggedinusername %] + + +
+ [% END # /casAuthentication %] + [% ELSIF ( OpacNavRight ) %] + [% IF Koha.Preference('OPACUserSummary') && dashboard_info %] +
+

Welcome, [% INCLUDE 'patron-title.inc' patron = logged_in_user %]

+ +
+ [% END %] [% END # /opacuserlogin %] [% PROCESS koha_news_block news => OpacNavRight %] -
- [% END # /opacuserlogin || OpacNavRight %] + [% END # /opacuserlogin || OpacNavRight %] + +
+ [% END %]
-- 2.20.1