From cf24d63fa498722010aff4b883ace873c28022bb Mon Sep 17 00:00:00 2001 From: rr- Date: Thu, 22 Dec 2016 23:37:30 +0100 Subject: [PATCH] client/css: fix lists in comments css inheritance Markdown lists in comments inherited some unwanted CSS rules. The fix is to make the culprit rules apply to more specific elements. --- client/css/core-forms.styl | 6 +-- client/css/post-list-view.styl | 2 +- client/css/post-upload.styl | 4 ++ client/css/tag-input-control.styl | 3 +- client/css/tag-list-view.styl | 2 +- client/css/user-list-view.styl | 2 +- client/html/login.tpl | 52 ++++++++++++------------ client/html/password_reset.tpl | 22 +++++------ client/html/post_merge.tpl | 2 +- client/html/tag_delete.tpl | 2 +- client/html/tag_edit.tpl | 2 +- client/html/tag_merge.tpl | 2 +- client/html/tags_header.tpl | 13 +++--- client/html/user_delete.tpl | 21 +++++----- client/html/user_registration.tpl | 66 +++++++++++++++---------------- client/html/users_header.tpl | 13 +++--- 16 files changed, 107 insertions(+), 107 deletions(-) diff --git a/client/css/core-forms.styl b/client/css/core-forms.styl index 5fe44e4f..8323d16e 100644 --- a/client/css/core-forms.styl +++ b/client/css/core-forms.styl @@ -4,17 +4,15 @@ form display: block width: 20em - ul + .input list-style-type: none - margin: 0 0 1em 0 + margin: 0 0 2em 0 padding: 0 li margin-top: 1.2em label display: block padding: 0.3em 0 - .input - margin-bottom: 2em .input li:first-child label:not(.radio):not(.checkbox):not(.file-dropper), .input li:first-child padding-top: 0 diff --git a/client/css/post-list-view.styl b/client/css/post-list-view.styl index b18fa64f..4e797e0c 100644 --- a/client/css/post-list-view.styl +++ b/client/css/post-list-view.styl @@ -106,7 +106,7 @@ text-align: left label - display: none + display: none !important form width: auto margin-bottom: 0.75em diff --git a/client/css/post-upload.styl b/client/css/post-upload.styl index f315236f..cd684315 100644 --- a/client/css/post-upload.styl +++ b/client/css/post-upload.styl @@ -39,6 +39,10 @@ $cancel-button-color = tomato margin-top: 1em .uploadables-container + list-style-type: none + margin: 0 + padding: 0 + li margin: 0 0 1.2em 0 diff --git a/client/css/tag-input-control.styl b/client/css/tag-input-control.styl index d4ee8657..7e9d0fcf 100644 --- a/client/css/tag-input-control.styl +++ b/client/css/tag-input-control.styl @@ -87,7 +87,8 @@ div.tag-input ul.compact-tags width: 100% - margin-top: 0.5em + margin: 0.5em 0 0 0 + padding: 0 li margin: 0 width: 100% diff --git a/client/css/tag-list-view.styl b/client/css/tag-list-view.styl index 410eb3dd..8ae7bcb8 100644 --- a/client/css/tag-list-view.styl +++ b/client/css/tag-list-view.styl @@ -41,7 +41,7 @@ .tag-list-header label - display: none + display: none !important text-align: left form width: auto diff --git a/client/css/user-list-view.styl b/client/css/user-list-view.styl index 1f3ada3b..3d49d941 100644 --- a/client/css/user-list-view.styl +++ b/client/css/user-list-view.styl @@ -28,7 +28,7 @@ .user-list-header label - display: none + display: none !important text-align: left form width: auto diff --git a/client/html/login.tpl b/client/html/login.tpl index ec63e6cb..cc2a6805 100644 --- a/client/html/login.tpl +++ b/client/html/login.tpl @@ -1,33 +1,33 @@

Log in

-
-
    -
  • - <%= ctx.makeTextInput({ - text: 'User name', - name: 'name', - required: true, - pattern: ctx.userNamePattern, - }) %> -
  • -
  • - <%= ctx.makePasswordInput({ - text: 'Password', - name: 'password', - required: true, - pattern: ctx.passwordPattern, - }) %> -
  • -
  • - <%= ctx.makeCheckbox({ - text: 'Remember me', - name: 'remember-user', - }) %> -
  • -
-
+
    +
  • + <%= ctx.makeTextInput({ + text: 'User name', + name: 'name', + required: true, + pattern: ctx.userNamePattern, + }) %> +
  • +
  • + <%= ctx.makePasswordInput({ + text: 'Password', + name: 'password', + required: true, + pattern: ctx.passwordPattern, + }) %> +
  • +
  • + <%= ctx.makeCheckbox({ + text: 'Remember me', + name: 'remember-user', + }) %> +
  • +
+
+
<% if (ctx.canSendMails) { %> diff --git a/client/html/password_reset.tpl b/client/html/password_reset.tpl index a4ccc7ea..b50b48ee 100644 --- a/client/html/password_reset.tpl +++ b/client/html/password_reset.tpl @@ -1,20 +1,20 @@

Password reset

-
-
    -
  • - <%= ctx.makeTextInput({ - text: 'User name or e-mail address', - name: 'user-name', - required: true, - }) %> -
  • -
-
+
    +
  • + <%= ctx.makeTextInput({ + text: 'User name or e-mail address', + name: 'user-name', + required: true, + }) %> +
  • +
+

Proceeding will send an e-mail that contains a password reset link. Clicking it is going to generate a new password for your account. It is recommended to change that password to something else.

+
diff --git a/client/html/post_merge.tpl b/client/html/post_merge.tpl index 59b3f495..9a59ba8c 100644 --- a/client/html/post_merge.tpl +++ b/client/html/post_merge.tpl @@ -1,6 +1,6 @@
-
    +
    • diff --git a/client/html/tag_delete.tpl b/client/html/tag_delete.tpl index 82736fc5..7dbfc1e6 100644 --- a/client/html/tag_delete.tpl +++ b/client/html/tag_delete.tpl @@ -2,7 +2,7 @@

      This tag has <%- ctx.tag.postCount %> usage(s).

      -
        +
        • <%= ctx.makeCheckbox({ name: 'confirm-deletion', diff --git a/client/html/tag_edit.tpl b/client/html/tag_edit.tpl index 0c896911..a58c529e 100644 --- a/client/html/tag_edit.tpl +++ b/client/html/tag_edit.tpl @@ -1,6 +1,6 @@
          -
            +
            • <% if (ctx.canEditNames) { %> <%= ctx.makeTextInput({ diff --git a/client/html/tag_merge.tpl b/client/html/tag_merge.tpl index ea1a7ec2..90d8aa63 100644 --- a/client/html/tag_merge.tpl +++ b/client/html/tag_merge.tpl @@ -1,6 +1,6 @@
              -
                +
                • <%= ctx.makeTextInput({required: true, text: 'Target tag', pattern: ctx.tagNamePattern}) %>
                • diff --git a/client/html/tags_header.tpl b/client/html/tags_header.tpl index a3d46416..ed641279 100644 --- a/client/html/tags_header.tpl +++ b/client/html/tags_header.tpl @@ -1,12 +1,11 @@
                  -
                  -
                    -
                  • - <%= ctx.makeTextInput({text: 'Search query', id: 'search-text', name: 'search-text', value: ctx.parameters.query}) %> -
                  • -
                  -
                  +
                    +
                  • + <%= ctx.makeTextInput({text: 'Search query', id: 'search-text', name: 'search-text', value: ctx.parameters.query}) %> +
                  • +
                  +
                  Syntax help diff --git a/client/html/user_delete.tpl b/client/html/user_delete.tpl index 9704492a..6d57630e 100644 --- a/client/html/user_delete.tpl +++ b/client/html/user_delete.tpl @@ -1,16 +1,15 @@
                  -
                  -
                    -
                  • - <%= ctx.makeCheckbox({ - name: 'confirm-deletion', - text: 'I confirm that I want to delete this account.', - required: true, - }) %> -
                  • -
                  -
                  +
                    +
                  • + <%= ctx.makeCheckbox({ + name: 'confirm-deletion', + text: 'I confirm that I want to delete this account.', + required: true, + }) %> +
                  • +
                  +
                  diff --git a/client/html/user_registration.tpl b/client/html/user_registration.tpl index 58321182..e0e0f81c 100644 --- a/client/html/user_registration.tpl +++ b/client/html/user_registration.tpl @@ -4,44 +4,44 @@ -
                  -
                    -
                  • - <%= ctx.makeTextInput({ - text: 'User name', - name: 'name', - placeholder: 'letters, digits, _, -', - required: true, - pattern: ctx.userNamePattern, - }) %> -
                  • -
                  • - <%= ctx.makePasswordInput({ - text: 'Password', - name: 'password', - placeholder: '5+ characters', - required: true, - pattern: ctx.passwordPattern, - }) %> -
                  • -
                  • - <%= ctx.makeEmailInput({ - text: 'Email', - name: 'email', - placeholder: 'optional', - }) %> -

                    - Used for password reminder and to show a Gravatar. - Leave blank for random Gravatar. -

                    -
                  • -
                  -
                  +
                    +
                  • + <%= ctx.makeTextInput({ + text: 'User name', + name: 'name', + placeholder: 'letters, digits, _, -', + required: true, + pattern: ctx.userNamePattern, + }) %> +
                  • +
                  • + <%= ctx.makePasswordInput({ + text: 'Password', + name: 'password', + placeholder: '5+ characters', + required: true, + pattern: ctx.passwordPattern, + }) %> +
                  • +
                  • + <%= ctx.makeEmailInput({ + text: 'Email', + name: 'email', + placeholder: 'optional', + }) %> +

                    + Used for password reminder and to show a Gravatar. + Leave blank for random Gravatar. +

                    +
                  • +
                  +
                  +

                  Registered users can:

                    diff --git a/client/html/users_header.tpl b/client/html/users_header.tpl index 5b7d38bc..6cefe556 100644 --- a/client/html/users_header.tpl +++ b/client/html/users_header.tpl @@ -1,12 +1,11 @@
                    -
                    -
                      -
                    • - <%= ctx.makeTextInput({text: 'Search query', id: 'search-text', name: 'search-text', value: ctx.parameters.query}) %> -
                    • -
                    -
                    +
                      +
                    • + <%= ctx.makeTextInput({text: 'Search query', id: 'search-text', name: 'search-text', value: ctx.parameters.query}) %> +
                    • +
                    +