From 78f5b91185eaba3fa82d650c6c40212e18809ceb Mon Sep 17 00:00:00 2001 From: Dan Marsden Date: Fri, 28 Sep 2018 10:49:41 +1200 Subject: [PATCH] Improve css tags, and make sure messages wrap correctly. --- db/mobile.php | 2 +- mobilestyles.css | 18 ++++++++++++------ templates/mobile_teacher_form.mustache | 2 +- templates/mobile_user_form.mustache | 10 ++++++---- templates/mobile_view_page.mustache | 10 ++++++---- 5 files changed, 26 insertions(+), 16 deletions(-) diff --git a/db/mobile.php b/db/mobile.php index b71e3de..25aab26 100644 --- a/db/mobile.php +++ b/db/mobile.php @@ -36,7 +36,7 @@ $addons = [ 'method' => 'mobile_view_activity', 'styles' => [ 'url' => '/mod/attendance/mobilestyles.css', - 'version' => 19 + 'version' => 21 ] ] ], diff --git a/mobilestyles.css b/mobilestyles.css index 33ad840..4588ed1 100644 --- a/mobilestyles.css +++ b/mobilestyles.css @@ -1,20 +1,26 @@ -.attendance_teacher_form .item-radio { +.attendance_mobile_teacher_form .item-radio { display: inline-block; margin-top: 10px; margin-left: 5px; padding: 0; width: 70px; } -.attendance_teacher_form .item-inner { +.attendance_mobile_teacher_form .item-inner { padding: 0; } -.attendance_teacher_form .radiolabel .item-inner { +.attendance_mobile_teacher_form .radiolabel .item-inner { text-align: center; } -.attendance_teacher_form .item-inner .input-wrapper label, -.attendance_teacher_form .radio { +.attendance_mobile_teacher_form .item-inner .input-wrapper label, +.attendance_mobile_teacher_form .radio { margin: 0; } -.attendance_teacher_form .radio .radio-icon { +.attendance_mobile_teacher_form .radio .radio-icon { display: none; +} + +.attendance_mobile_teacher_form .messages .label, +.attendance_mobile_user_form .messages .label, +.attendance_mobile_view_page .messages .label { + white-space: normal; } \ No newline at end of file diff --git a/templates/mobile_teacher_form.mustache b/templates/mobile_teacher_form.mustache index 6760cdd..d4d5c0f 100644 --- a/templates/mobile_teacher_form.mustache +++ b/templates/mobile_teacher_form.mustache @@ -45,7 +45,7 @@ } }} {{=<% %>=}} -
+
diff --git a/templates/mobile_user_form.mustache b/templates/mobile_user_form.mustache index 41c9a0e..b47502d 100644 --- a/templates/mobile_user_form.mustache +++ b/templates/mobile_user_form.mustache @@ -44,13 +44,15 @@ } }} {{=<% %>=}} -
+
<%#showmessage%> <%#messages%> - - {{ 'plugin.mod_attendance.<% string %>' | translate }} - + + + {{ 'plugin.mod_attendance.<% string %>' | translate }} + + <%/messages%> <%/showmessage%> <%#showpassword%> diff --git a/templates/mobile_view_page.mustache b/templates/mobile_view_page.mustache index 217d12b..ed0777e 100644 --- a/templates/mobile_view_page.mustache +++ b/templates/mobile_view_page.mustache @@ -48,13 +48,15 @@ } }} {{=<% %>=}} -
+
<%#showmessage%> <%#messages%> - - {{ 'plugin.mod_attendance.<% string %>' | translate }} - + + + {{ 'plugin.mod_attendance.<% string %>' | translate }} + + <%/messages%> <%/showmessage%> <%#sessions%>