From bebd7bcebbcd8a5068734272243b61f505faefc3 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Thu, 16 Nov 2023 17:24:27 +0000 Subject: [PATCH] Bug 35348: Add cookies link to opac footer This patch adds a link to prompt the cookies info dialogue into the opac footer when the CookieConsent feature is enabled. --- .../opac-tmpl/bootstrap/css/src/opac.scss | 18 +++++ .../bootstrap/en/includes/masthead.inc | 2 +- .../bootstrap/en/includes/opac-bottom.inc | 75 +++++++++++-------- .../opac-tmpl/bootstrap/js/cookieconsent.js | 2 +- 4 files changed, 63 insertions(+), 34 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss index 33aaf5054bd..233a1c13ac2 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss +++ b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss @@ -428,6 +428,24 @@ th { } } +#footernav { + li { + display: inline-block; + padding-right: 5px; + white-space: nowrap; + + &::after { + content: " | "; + } + + &:last-child { + &::after { + content: ""; + } + } + } +} + #news { margin: .5em 0; padding: 1em; diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc index 4f12b883076..0118401ad48 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc +++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc @@ -465,7 +465,7 @@ [% END %] - + diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc index 943c862eaba..4d9a2482f0c 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc +++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc @@ -20,40 +20,51 @@ [% END #/ opaccredits %] - - [% IF ( Koha.Preference('OPACReportProblem') && Koha.Preference('KohaAdminEmailAddress') ) || OpacKohaUrl %] -
-
-
-
-
- [% IF Koha.Preference('OPACReportProblem') && Koha.Preference('KohaAdminEmailAddress') %] - - [% END # / IF Koha.Preference('OPACReportProblem') && Koha.Preference('KohaAdminEmailAddress') %] - [% IF OpacKohaUrl %] -
-
-

Powered by - [% IF template.name.match('opac-main.tt') %] - Koha - [% ELSE %] - Koha - [% END %]

-
-
- [% END # /IF OpacKohaUrl %] -
-
-
-
-
- [% END # / OPACReportProblem || OpacKohaUrl %] + [% IF ( Koha.Preference('OPACReportProblem') && Koha.Preference('KohaAdminEmailAddress') ) || Koha.Preference( 'CookieConsent' ) || OpacKohaUrl %] + + [% END # / OPACReportProblem || OpacKohaUrl %] + [% IF OpacLangSelectorMode == 'both' || OpacLangSelectorMode == 'footer' %] [% IF ( Koha.Preference('opaclanguagesdisplay') ) %] [% IF ( languages_loop ) %] diff --git a/koha-tmpl/opac-tmpl/bootstrap/js/cookieconsent.js b/koha-tmpl/opac-tmpl/bootstrap/js/cookieconsent.js index 088d3ba2aa3..e1e64b390bd 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/js/cookieconsent.js +++ b/koha-tmpl/opac-tmpl/bootstrap/js/cookieconsent.js @@ -183,7 +183,7 @@ }); // "More information" handler - $('#consentMoreInfo, #cookieConsentButton, #viewCookieConsents').on( + $('.consentMoreInfo, #cookieConsentButton, #viewCookieConsents').on( 'click', function (e) { e.preventDefault(); -- 2.41.0