From b459ca667a0e8e8da967354a7459cf5fafa0d1e2 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Wed, 1 Sep 2021 12:12:04 +0000 Subject: [PATCH] Bug 28934: Correct markup of GDPR consent in OPAC patron entry This patch makes changes to the markup around the GDPR consent checkbox in the OPAC self-registration / update page to make it more consistent with other form fields on the page. The patch also adds some missing attributes which are required to enable JavaScript validation of the checkbox. To test, apply the patch and rebuild the OPAC CSS (https://wiki.koha-community.org/wiki/Working_with_SCSS_in_the_OPAC_and_staff_client). - Go to Administration -> System preferences and Enable the system preference PatronSelfRegistration. - Set the system preference GDPR_Policy to "Enforce". - Go to the OPAC and click the "Register here" link. - Under the "GDPR consent" heading near the bottom of the page, confirm that the "I agree" checkbox lines up with other form fields on the page, and that the "Required" label lines up below it. - Submit the form without checking the GDPR consent checkbox. - The form should not be submitted, and a "This field is required" message should appear next to the checkbox label. --- koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss | 10 +++++++++- .../opac-tmpl/bootstrap/en/modules/opac-memberentry.tt | 10 +++++++--- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss index c665cfea5d..9f6c4701e2 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss +++ b/koha-tmpl/opac-tmpl/bootstrap/css/src/opac.scss @@ -774,13 +774,21 @@ fieldset { width: 100%; &.lradio { - padding-left: 8.5em; + padding-left: 9rem; width: auto; label { float: none; margin: 0 0 0 1em; width: auto; + + &.error { + float: right; + } + } + + .required_label { + margin-left: 1em; } } } diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-memberentry.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-memberentry.tt index 7f1ad4a58a..7d85f167a5 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-memberentry.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-memberentry.tt @@ -957,9 +957,13 @@ -- 2.20.1