aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZarino Zappia <mail@zarino.co.uk>2019-05-01 20:07:11 +0100
committerMatthew Somerville <matthew-github@dracos.co.uk>2019-05-02 07:43:12 +0100
commit26d2bb9dddb0f9e10267ec47dbcb4a1571021a8b (patch)
treed285122f2ec320fc498b3fc9601a353e8e470096
parent1a1422783f9ffd10970e4b4439bee32f3ceb8fc7 (diff)
Custom layout for admin user permission checkboxes
-rw-r--r--CHANGELOG.md1
-rw-r--r--templates/web/base/admin/users/form.html2
-rw-r--r--web/cobrands/sass/_admin.scss23
3 files changed, 25 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3967b8d92..ebcf7c1dc 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -16,6 +16,7 @@
- Allow searching for <email> in admin.
- Make staff JavaScript more self-contained.
- Alow staff user to be associated with multiple areas.
+ - Improvements to admin checkbox display.
- Bugfixes:
- Check cached reports do still have photos before being shown. #2374
- Delete cache photos upon photo moderation. #2374
diff --git a/templates/web/base/admin/users/form.html b/templates/web/base/admin/users/form.html
index 6facd5c8a..8f0f9ad6e 100644
--- a/templates/web/base/admin/users/form.html
+++ b/templates/web/base/admin/users/form.html
@@ -164,7 +164,7 @@
</div>
[% loc('Permissions:') %]
</legend>
- <ul>
+ <ul class="permissions-checkboxes">
[% FOREACH group IN available_permissions.pairs %]
<li>
[% group.key %]
diff --git a/web/cobrands/sass/_admin.scss b/web/cobrands/sass/_admin.scss
index 8b701cfc6..1f55c62df 100644
--- a/web/cobrands/sass/_admin.scss
+++ b/web/cobrands/sass/_admin.scss
@@ -217,3 +217,26 @@ $button_bg_col: #a1a1a1; // also search bar (tables)
.danger-zone {
text-align: #{$right};
}
+
+.permissions-checkboxes {
+ margin: 0;
+
+ & > li {
+ border-top: 1px solid $table_border_color;
+ list-style: none;
+ padding: 0;
+ margin: 1em 0;
+ padding-top: 1em;
+ font-weight: bold;
+
+ @media (min-width: 48em) {
+ display: grid;
+ grid-template-columns: 10em auto;
+ grid-column-gap: 1em;
+ }
+ }
+
+ ul {
+ font-weight: normal;
+ }
+}