From 902d0e1e3a61bc2d2d05c617a6e8e51aaaf42b30 Mon Sep 17 00:00:00 2001 From: Joffrey JAFFEUX Date: Tue, 11 Feb 2020 15:55:16 +0100 Subject: [PATCH] DEV: enforces no-invalid-interactive linting rule (#8907) --- .template-lintrc.js | 3 +- .../admin/templates/api-keys-show.hbs | 4 +- .../admin/templates/badges-show.hbs | 6 ++- .../components/admin-editable-field.hbs | 4 +- .../components/admin-theme-editor.hbs | 41 ++++++++++--------- .../templates/components/site-setting.hbs | 2 +- .../templates/components/themes-list-item.hbs | 4 +- .../templates/components/themes-list.hbs | 19 ++++++--- .../admin/templates/customize-themes-show.hbs | 8 +++- .../admin/templates/email-bounced.hbs | 2 +- .../admin/templates/email-rejected.hbs | 2 +- .../templates/logs/screened-ip-addresses.hbs | 6 +-- .../templates/logs/staff-action-logs.hbs | 22 +++++----- .../modal/admin-uploaded-image-list.hbs | 4 +- .../admin/templates/web-hooks-show-events.hbs | 4 +- .../templates/components/basic-topic-list.hbs | 8 ++-- .../components/composer-user-selector.hbs | 10 +++-- .../templates/components/d-modal-cancel.hbs | 2 +- .../templates/components/expand-post.hbs | 4 +- .../components/group-manage-logs-row.hbs | 11 +++-- .../templates/components/group-member.hbs | 10 ++++- .../templates/components/ip-lookup.hbs | 2 +- .../components/reviewable-flagged-post.hbs | 2 +- .../templates/components/reviewable-item.hbs | 2 +- .../templates/components/signup-cta.hbs | 2 +- .../templates/components/tag-info.hbs | 4 +- .../discourse/templates/composer.hbs | 2 +- .../discourse/templates/discovery/topics.hbs | 8 ++-- .../discourse/templates/full-page-search.hbs | 4 +- .../mobile/components/basic-topic-list.hbs | 6 +-- .../mobile/components/mobile-nav.hbs | 7 +++- .../mobile/components/navigation-bar.hbs | 2 +- .../templates/mobile/discovery/topics.hbs | 4 +- .../templates/mobile/modal/login.hbs | 2 +- .../discourse/templates/modal/auth-token.hbs | 2 +- .../templates/modal/avatar-selector.hbs | 4 +- .../templates/modal/group-bulk-add.hbs | 2 +- .../discourse/templates/modal/login.hbs | 2 +- .../modal/second-factor-add-totp.hbs | 2 +- .../templates/preferences/account.hbs | 4 +- .../discourse/templates/tags/index.hbs | 4 +- .../templates/user-private-messages-tags.hbs | 12 +++++- .../javascripts/discourse/templates/user.hbs | 2 +- .../stylesheets/common/admin/admin_base.scss | 5 +++ .../stylesheets/common/admin/customize.scss | 19 ++++----- app/assets/stylesheets/common/base/alert.scss | 4 ++ 46 files changed, 163 insertions(+), 122 deletions(-) diff --git a/.template-lintrc.js b/.template-lintrc.js index e467fa2784d..5731778fc04 100644 --- a/.template-lintrc.js +++ b/.template-lintrc.js @@ -5,6 +5,7 @@ module.exports = { rules: { "self-closing-void-elements": true, "table-groups": true, - "style-concatenation": true + "style-concatenation": true, + "no-invalid-interactive": true } }; diff --git a/app/assets/javascripts/admin/templates/api-keys-show.hbs b/app/assets/javascripts/admin/templates/api-keys-show.hbs index 098d727f826..b96bc109b38 100644 --- a/app/assets/javascripts/admin/templates/api-keys-show.hbs +++ b/app/assets/javascripts/admin/templates/api-keys-show.hbs @@ -13,7 +13,9 @@ {{#if editingDescription}} {{input value=buffered.description maxlength="255" placeholder=(i18n "admin.api.description_placeholder")}} {{else}} - {{if model.description model.description (i18n "admin.api.no_description")}} + + {{if model.description model.description (i18n "admin.api.no_description")}} + {{/if}}
diff --git a/app/assets/javascripts/admin/templates/badges-show.hbs b/app/assets/javascripts/admin/templates/badges-show.hbs index 22059535e77..f3935c4f2fc 100644 --- a/app/assets/javascripts/admin/templates/badges-show.hbs +++ b/app/assets/javascripts/admin/templates/badges-show.hbs @@ -163,7 +163,11 @@ label="admin.badges.save"}} {{savingStatus}} {{#unless readOnly}} - {{i18n 'admin.badges.delete'}} + {{d-button + action=(action "destroy") + class="btn-danger" + label="admin.badges.delete" + }} {{/unless}}
diff --git a/app/assets/javascripts/admin/templates/components/admin-editable-field.hbs b/app/assets/javascripts/admin/templates/components/admin-editable-field.hbs index ee44e3c9bcc..05250286a8a 100644 --- a/app/assets/javascripts/admin/templates/components/admin-editable-field.hbs +++ b/app/assets/javascripts/admin/templates/components/admin-editable-field.hbs @@ -3,7 +3,9 @@ {{#if editing}} {{text-field value=buffer autofocus="autofocus" autocomplete="discourse"}} {{else}} - {{value}} + + {{value}} + {{/if}}
diff --git a/app/assets/javascripts/admin/templates/components/admin-theme-editor.hbs b/app/assets/javascripts/admin/templates/components/admin-theme-editor.hbs index 049563bd555..bf9d2fd3cbc 100644 --- a/app/assets/javascripts/admin/templates/components/admin-theme-editor.hbs +++ b/app/assets/javascripts/admin/templates/components/admin-theme-editor.hbs @@ -4,11 +4,11 @@ {{#each visibleTargets as |target|}}
  • {{#link-to editRouteName - theme.id - target.name - fieldName - replace=true - title=field.title + theme.id + target.name + fieldName + replace=true + title=field.title class=(if target.edited 'edited' 'blank') }} {{#if target.error}}{{d-icon 'exclamation-triangle'}}{{/if}} @@ -19,14 +19,15 @@ {{/link-to}}
  • {{/each}} - + {{#if allowAdvanced}}
  • - - {{d-icon (if showAdvanced "angle-double-left" "angle-double-right")}} + {{d-icon (if showAdvanced "angle-double-left" "angle-double-right")}}
  • {{/if}} @@ -48,17 +49,17 @@ {{#each visibleFields as |field|}}
  • {{#link-to editRouteName - theme.id - currentTargetName - field.name - replace=true - title=field.title + theme.id + currentTargetName + field.name + replace=true + title=field.title class=(if field.edited 'edited' 'blank') }} {{#if field.error}}{{d-icon 'exclamation-triangle'}}{{/if}} {{#if field.icon}}{{d-icon field.icon}}{{/if}} {{field.translatedName}} - + {{/link-to}}
  • {{/each}} @@ -66,11 +67,11 @@ {{#if showAddField}}
  • {{#if addingField}} - {{input type=text value=newFieldName enter=(action 'addField') escape-press=(action "cancelAddField")}} - {{d-button class="ok" action=(action "addField" newFieldName) icon="check"}} + {{input type=text value=newFieldName enter=(action 'addField') escape-press=(action "cancelAddField")}} + {{d-button class="ok" action=(action "addField" newFieldName) icon="check"}} {{d-button class="cancel" action=(action "cancelAddField") icon="times"}} {{else}} - + {{d-icon "plus"}} {{/if}} @@ -78,8 +79,8 @@ {{/if}}
  • - - {{d-icon maximizeIcon}} + + {{d-icon maximizeIcon}}
  • diff --git a/app/assets/javascripts/admin/templates/components/site-setting.hbs b/app/assets/javascripts/admin/templates/components/site-setting.hbs index e67af557517..649df86a4fc 100644 --- a/app/assets/javascripts/admin/templates/components/site-setting.hbs +++ b/app/assets/javascripts/admin/templates/components/site-setting.hbs @@ -1,7 +1,7 @@

    {{unbound settingName}}

    {{#if defaultIsAvailable}} - {{setting.setDefaultValuesLabel}} + {{setting.setDefaultValuesLabel}} {{/if}}
    diff --git a/app/assets/javascripts/admin/templates/components/themes-list-item.hbs b/app/assets/javascripts/admin/templates/components/themes-list-item.hbs index aba96d1917b..363ca394ec2 100644 --- a/app/assets/javascripts/admin/templates/components/themes-list-item.hbs +++ b/app/assets/javascripts/admin/templates/components/themes-list-item.hbs @@ -31,13 +31,13 @@ {{{childrenString}}} {{#if displayHasMore}} - + {{#if childrenExpanded}} {{I18n "admin.customize.theme.collapse"}} {{else}} {{I18n "admin.customize.theme.and_x_more" count=moreCount}} {{/if}} - + {{/if}}
    {{/if}} diff --git a/app/assets/javascripts/admin/templates/components/themes-list.hbs b/app/assets/javascripts/admin/templates/components/themes-list.hbs index 1f0c7fc2d54..29935b95b8c 100644 --- a/app/assets/javascripts/admin/templates/components/themes-list.hbs +++ b/app/assets/javascripts/admin/templates/components/themes-list.hbs @@ -1,10 +1,17 @@
    -
    - {{I18n "admin.customize.theme.title"}} -
    - {{d-icon "puzzle-piece"}} - {{I18n "admin.customize.theme.components"}} -
    + {{d-button + action=(action "changeView") + actionParam=THEMES + class=(concat "themes-tab " "tab " (if themesTabActive 'btn-danger active' '')) + label="admin.customize.theme.title" + }} + {{d-button + action=(action "changeView") + actionParam=COMPONENTS + class=(concat "components-tab " "tab " (if componentsTabActive 'btn-danger active' '')) + label="admin.customize.theme.components" + icon="puzzle-piece" + }}
    diff --git a/app/assets/javascripts/admin/templates/customize-themes-show.hbs b/app/assets/javascripts/admin/templates/customize-themes-show.hbs index 092991f1a32..de6b46da746 100644 --- a/app/assets/javascripts/admin/templates/customize-themes-show.hbs +++ b/app/assets/javascripts/admin/templates/customize-themes-show.hbs @@ -3,9 +3,13 @@ {{#if editingName}} {{text-field value=model.name autofocus="true"}} {{d-button action=(action "finishedEditingName") class="btn-primary submit-edit" icon="check"}} - {{d-button action=(action "cancelEditingName") class="btn-default cancel-edit" icon="times"}} + {{d-button action=(action "cancelEditingName") class="cancel-edit" icon="times"}} {{else}} - {{model.name}} {{d-icon "pencil-alt"}} + {{model.name}} + {{d-button + action=(action "startEditingName") + icon="pencil-alt" + }} {{/if}}
    diff --git a/app/assets/javascripts/admin/templates/email-bounced.hbs b/app/assets/javascripts/admin/templates/email-bounced.hbs index 700f3907e99..0387050d8fc 100644 --- a/app/assets/javascripts/admin/templates/email-bounced.hbs +++ b/app/assets/javascripts/admin/templates/email-bounced.hbs @@ -29,7 +29,7 @@ {{l.to_address}} {{#if l.has_bounce_key}} - {{l.email_type}} + {{l.email_type}} {{else}} {{l.email_type}} {{/if}} diff --git a/app/assets/javascripts/admin/templates/email-rejected.hbs b/app/assets/javascripts/admin/templates/email-rejected.hbs index 7139d85e2fb..e3595a58bd2 100644 --- a/app/assets/javascripts/admin/templates/email-rejected.hbs +++ b/app/assets/javascripts/admin/templates/email-rejected.hbs @@ -48,7 +48,7 @@ {{email.subject}} - {{email.error}} + {{email.error}} {{else}} diff --git a/app/assets/javascripts/admin/templates/logs/screened-ip-addresses.hbs b/app/assets/javascripts/admin/templates/logs/screened-ip-addresses.hbs index 109e7e32e1a..f9220965a2b 100644 --- a/app/assets/javascripts/admin/templates/logs/screened-ip-addresses.hbs +++ b/app/assets/javascripts/admin/templates/logs/screened-ip-addresses.hbs @@ -42,13 +42,13 @@ {{#if item.editing}} {{text-field value=item.ip_address autofocus="autofocus"}} {{else}} - + {{#if item.isRange}} {{item.ip_address}} {{else}} {{item.ip_address}} {{/if}} - + {{/if}} @@ -108,7 +108,7 @@ action=(action "save") actionParam=item label="admin.logs.save"}} - {{i18n "cancel"}} + {{i18n "cancel"}} {{/unless}} diff --git a/app/assets/javascripts/admin/templates/logs/staff-action-logs.hbs b/app/assets/javascripts/admin/templates/logs/staff-action-logs.hbs index d48127916ac..57eb988901c 100644 --- a/app/assets/javascripts/admin/templates/logs/staff-action-logs.hbs +++ b/app/assets/javascripts/admin/templates/logs/staff-action-logs.hbs @@ -1,29 +1,29 @@
    {{#if filtersExists}}
    - + {{i18n 'admin.logs.staff_actions.clear_filters'}} {{#if actionFilter}} - + {{i18n 'admin.logs.action'}}: {{actionFilter}} {{d-icon "times-circle"}} {{/if}} {{#if filters.acting_user}} - + {{i18n 'admin.logs.staff_actions.staff_user'}}: {{filters.acting_user}} {{d-icon "times-circle"}} {{/if}} {{#if filters.target_user}} - + {{i18n 'admin.logs.staff_actions.target_user'}}: {{filters.target_user}} {{d-icon "times-circle"}} {{/if}} {{#if filters.subject}} - + {{i18n 'admin.logs.staff_actions.subject'}}: {{filters.subject}} {{d-icon "times-circle"}} @@ -63,7 +63,7 @@
    {{#if item.acting_user}} {{#link-to 'adminUser' item.acting_user}}{{avatar item.acting_user imageSize="tiny"}}{{/link-to}} - {{item.acting_user.username}} + {{item.acting_user.username}} {{else}} {{d-icon "far-trash-alt"}} @@ -72,16 +72,16 @@
    - {{item.actionName}} + {{item.actionName}}
    {{#if item.target_user}} {{#link-to 'adminUser' item.target_user}}{{avatar item.target_user imageSize="tiny"}}{{/link-to}} - {{item.target_user.username}} + {{item.target_user.username}} {{/if}} {{#if item.subject}} - {{item.subject}} + {{item.subject}} {{/if}}
    @@ -89,10 +89,10 @@ {{{item.formattedDetails}}} {{#if item.useCustomModalForDetails}} - {{d-icon "info-circle"}} {{i18n 'admin.logs.staff_actions.show'}} + {{d-icon "info-circle"}} {{i18n 'admin.logs.staff_actions.show'}} {{/if}} {{#if item.useModalForDetails}} - {{d-icon "info-circle"}} {{i18n 'admin.logs.staff_actions.show'}} + {{d-icon "info-circle"}} {{i18n 'admin.logs.staff_actions.show'}} {{/if}} {{item.context}} diff --git a/app/assets/javascripts/admin/templates/modal/admin-uploaded-image-list.hbs b/app/assets/javascripts/admin/templates/modal/admin-uploaded-image-list.hbs index 10af81306cb..178f39075ce 100644 --- a/app/assets/javascripts/admin/templates/modal/admin-uploaded-image-list.hbs +++ b/app/assets/javascripts/admin/templates/modal/admin-uploaded-image-list.hbs @@ -1,9 +1,9 @@ {{#d-modal-body class="uploaded-image-list"}}
    {{#each images as |image|}} - + {{else}}

    {{i18n "admin.site_settings.uploaded_image_list.empty"}}

    {{/each}} diff --git a/app/assets/javascripts/admin/templates/web-hooks-show-events.hbs b/app/assets/javascripts/admin/templates/web-hooks-show-events.hbs index 5b7b1e8e37c..38e4d2215fb 100644 --- a/app/assets/javascripts/admin/templates/web-hooks-show-events.hbs +++ b/app/assets/javascripts/admin/templates/web-hooks-show-events.hbs @@ -21,9 +21,9 @@
    {{#if hasIncoming}} - + {{/if}}
      {{#each model as |webHookEvent|}} diff --git a/app/assets/javascripts/discourse/templates/components/basic-topic-list.hbs b/app/assets/javascripts/discourse/templates/components/basic-topic-list.hbs index 44d9dc579d8..b047846db56 100644 --- a/app/assets/javascripts/discourse/templates/components/basic-topic-list.hbs +++ b/app/assets/javascripts/discourse/templates/components/basic-topic-list.hbs @@ -1,11 +1,9 @@ {{#conditional-loading-spinner condition=loading}} {{#if hasIncoming}} {{/if}} diff --git a/app/assets/javascripts/discourse/templates/components/composer-user-selector.hbs b/app/assets/javascripts/discourse/templates/components/composer-user-selector.hbs index 21c69bda7ad..bf894877412 100644 --- a/app/assets/javascripts/discourse/templates/components/composer-user-selector.hbs +++ b/app/assets/javascripts/discourse/templates/components/composer-user-selector.hbs @@ -10,8 +10,10 @@ allowEmails='true' autocomplete="discourse"}} {{else}} -
      - {{limitedUsernames}} - {{hiddenUsersCount}} -
      + +
      + {{limitedUsernames}} + {{hiddenUsersCount}} +
      +
      {{/if}} diff --git a/app/assets/javascripts/discourse/templates/components/d-modal-cancel.hbs b/app/assets/javascripts/discourse/templates/components/d-modal-cancel.hbs index e4fc5950d95..f61b3ed7c7c 100644 --- a/app/assets/javascripts/discourse/templates/components/d-modal-cancel.hbs +++ b/app/assets/javascripts/discourse/templates/components/d-modal-cancel.hbs @@ -1 +1 @@ -{{i18n 'cancel'}} +{{i18n 'cancel'}} diff --git a/app/assets/javascripts/discourse/templates/components/expand-post.hbs b/app/assets/javascripts/discourse/templates/components/expand-post.hbs index 63716b696c1..ffb1ea66134 100644 --- a/app/assets/javascripts/discourse/templates/components/expand-post.hbs +++ b/app/assets/javascripts/discourse/templates/components/expand-post.hbs @@ -1,10 +1,10 @@ {{#if item.truncated}} {{#if expanded}} - + {{d-icon "chevron-up"}} {{else}} - + {{d-icon "chevron-down"}} {{/if}} diff --git a/app/assets/javascripts/discourse/templates/components/group-manage-logs-row.hbs b/app/assets/javascripts/discourse/templates/components/group-manage-logs-row.hbs index d7754b460c8..dd929c5617d 100644 --- a/app/assets/javascripts/discourse/templates/components/group-manage-logs-row.hbs +++ b/app/assets/javascripts/discourse/templates/components/group-manage-logs-row.hbs @@ -33,13 +33,12 @@ {{bound-date log.created_at}} - + {{#if log.prev_value}} - {{#if expandDetails}} - {{d-icon 'ellipsis-v'}} - {{else}} - {{d-icon 'ellipsis-h'}} - {{/if}} + {{d-button + action=(action "toggleDetails") + icon=(if expandDetails "angle-up" "angle-down") + }} {{/if}} diff --git a/app/assets/javascripts/discourse/templates/components/group-member.hbs b/app/assets/javascripts/discourse/templates/components/group-member.hbs index ddc6456b833..dcdfc050d6f 100644 --- a/app/assets/javascripts/discourse/templates/components/group-member.hbs +++ b/app/assets/javascripts/discourse/templates/components/group-member.hbs @@ -1 +1,9 @@ -{{avatar member imageSize="small"}} {{member.username}} {{#unless automatic}}{{d-icon "times"}}{{/unless}} + + {{avatar member imageSize="small"}} + +{{member.username}} +{{#unless automatic}} + + {{d-icon "times"}} + +{{/unless}} diff --git a/app/assets/javascripts/discourse/templates/components/ip-lookup.hbs b/app/assets/javascripts/discourse/templates/components/ip-lookup.hbs index 73c0ab7851f..9c9c2d39509 100644 --- a/app/assets/javascripts/discourse/templates/components/ip-lookup.hbs +++ b/app/assets/javascripts/discourse/templates/components/ip-lookup.hbs @@ -7,7 +7,7 @@ {{/if}} {{#if show}}
      - {{d-icon "times"}} + {{d-icon "times"}} {{#if copied}} {{d-button class="btn-hover pull-right" icon="copy" label="ip_lookup.copied"}} {{else}} diff --git a/app/assets/javascripts/discourse/templates/components/reviewable-flagged-post.hbs b/app/assets/javascripts/discourse/templates/components/reviewable-flagged-post.hbs index e6bb87508a9..09e196766fb 100644 --- a/app/assets/javascripts/discourse/templates/components/reviewable-flagged-post.hbs +++ b/app/assets/javascripts/discourse/templates/components/reviewable-flagged-post.hbs @@ -1,7 +1,7 @@
      {{reviewable-topic-link reviewable=reviewable tagName=''}} {{#if hasEdits}} - {{d-icon "pencil-alt"}} diff --git a/app/assets/javascripts/discourse/templates/components/reviewable-item.hbs b/app/assets/javascripts/discourse/templates/components/reviewable-item.hbs index de34e55b582..d20294f4b52 100644 --- a/app/assets/javascripts/discourse/templates/components/reviewable-item.hbs +++ b/app/assets/javascripts/discourse/templates/components/reviewable-item.hbs @@ -10,7 +10,7 @@ {{reviewable-status reviewable.status}} - + {{d-icon "question-circle"}}
      diff --git a/app/assets/javascripts/discourse/templates/components/signup-cta.hbs b/app/assets/javascripts/discourse/templates/components/signup-cta.hbs index 1498e7b0053..f6587b40439 100644 --- a/app/assets/javascripts/discourse/templates/components/signup-cta.hbs +++ b/app/assets/javascripts/discourse/templates/components/signup-cta.hbs @@ -10,7 +10,7 @@
      {{d-button action=(route-action "showCreateAccount") label="signup_cta.sign_up" icon="check" class="btn-primary"}} {{d-button action=(action "hideForSession") label="signup_cta.hide_session" class="no-icon"}} - {{i18n "signup_cta.hide_forever"}} + {{i18n "signup_cta.hide_forever"}}
      {{/if}}
      diff --git a/app/assets/javascripts/discourse/templates/components/tag-info.hbs b/app/assets/javascripts/discourse/templates/components/tag-info.hbs index feabad1cbc6..3b616fec811 100644 --- a/app/assets/javascripts/discourse/templates/components/tag-info.hbs +++ b/app/assets/javascripts/discourse/templates/components/tag-info.hbs @@ -38,10 +38,10 @@
      {{discourse-tag tag.id pmOnly=tag.pmOnly tagName="div"}} {{#if editSynonymsMode}} - + {{d-icon "unlink" title="tagging.remove_synonym"}} - + {{d-icon "far-trash-alt" title="tagging.delete_tag"}} {{/if}} diff --git a/app/assets/javascripts/discourse/templates/composer.hbs b/app/assets/javascripts/discourse/templates/composer.hbs index 0f11a312cd3..ffc9fb49a41 100644 --- a/app/assets/javascripts/discourse/templates/composer.hbs +++ b/app/assets/javascripts/discourse/templates/composer.hbs @@ -196,7 +196,7 @@ {{/if}} - + {{d-icon "desktop"}} diff --git a/app/assets/javascripts/discourse/templates/discovery/topics.hbs b/app/assets/javascripts/discourse/templates/discovery/topics.hbs index e7b2d385ada..5413f9d9bfc 100644 --- a/app/assets/javascripts/discourse/templates/discovery/topics.hbs +++ b/app/assets/javascripts/discourse/templates/discovery/topics.hbs @@ -44,11 +44,9 @@ {{else}} {{#if topicTrackingState.hasIncoming}} {{/if}} {{/if}} diff --git a/app/assets/javascripts/discourse/templates/full-page-search.hbs b/app/assets/javascripts/discourse/templates/full-page-search.hbs index 56082d42ce9..1317bbc7532 100644 --- a/app/assets/javascripts/discourse/templates/full-page-search.hbs +++ b/app/assets/javascripts/discourse/templates/full-page-search.hbs @@ -41,8 +41,8 @@ {{#if bulkSelectEnabled}} {{/if}}
      diff --git a/app/assets/javascripts/discourse/templates/mobile/components/basic-topic-list.hbs b/app/assets/javascripts/discourse/templates/mobile/components/basic-topic-list.hbs index a344ce85975..7c68ac0d05f 100644 --- a/app/assets/javascripts/discourse/templates/mobile/components/basic-topic-list.hbs +++ b/app/assets/javascripts/discourse/templates/mobile/components/basic-topic-list.hbs @@ -1,9 +1,9 @@ {{#conditional-loading-spinner condition=loading}} {{#if hasIncoming}} {{/if}} @@ -17,7 +17,7 @@ {{topic-status topic=t}} {{topic-link t}} {{raw "list/unread-indicator" includeUnreadIndicator=showUnreadIndicator - topicId=t.id + topicId=t.id unreadClass=(if t.unread_by_group_member "" "read")}} {{#if t.unseen}} diff --git a/app/assets/javascripts/discourse/templates/mobile/components/mobile-nav.hbs b/app/assets/javascripts/discourse/templates/mobile/components/mobile-nav.hbs index 83bdf44a111..bebe6a385e4 100644 --- a/app/assets/javascripts/discourse/templates/mobile/components/mobile-nav.hbs +++ b/app/assets/javascripts/discourse/templates/mobile/components/mobile-nav.hbs @@ -1,7 +1,10 @@ {{#if selectedHtml}} -
    • {{{selectedHtml}}} +
    • + + {{{selectedHtml}}} {{d-icon "caret-down"}} -
    • + + {{/if}}
        {{yield}} diff --git a/app/assets/javascripts/discourse/templates/mobile/components/navigation-bar.hbs b/app/assets/javascripts/discourse/templates/mobile/components/navigation-bar.hbs index 9d1ffb0932a..d760be82d27 100644 --- a/app/assets/javascripts/discourse/templates/mobile/components/navigation-bar.hbs +++ b/app/assets/javascripts/discourse/templates/mobile/components/navigation-bar.hbs @@ -1,5 +1,5 @@
      {{else}} {{#if topicTrackingState.hasIncoming}} - + {{/if}} {{/if}} diff --git a/app/assets/javascripts/discourse/templates/mobile/modal/login.hbs b/app/assets/javascripts/discourse/templates/mobile/modal/login.hbs index 679308b4ac7..862a2fdd798 100644 --- a/app/assets/javascripts/discourse/templates/mobile/modal/login.hbs +++ b/app/assets/javascripts/discourse/templates/mobile/modal/login.hbs @@ -32,7 +32,7 @@ - {{i18n 'forgot_password.action'}} + {{i18n 'forgot_password.action'}} diff --git a/app/assets/javascripts/discourse/templates/modal/auth-token.hbs b/app/assets/javascripts/discourse/templates/modal/auth-token.hbs index 665a4e7e26c..1b08a4974bc 100644 --- a/app/assets/javascripts/discourse/templates/modal/auth-token.hbs +++ b/app/assets/javascripts/discourse/templates/modal/auth-token.hbs @@ -17,7 +17,7 @@

      {{i18n 'user.auth_tokens.latest_post'}} - {{d-icon (if expanded "caret-up" "caret-down")}} + {{d-icon (if expanded "caret-up" "caret-down")}}

      {{#if expanded}} diff --git a/app/assets/javascripts/discourse/templates/modal/avatar-selector.hbs b/app/assets/javascripts/discourse/templates/modal/avatar-selector.hbs index 59bb27619e4..cdaab1cc1c1 100644 --- a/app/assets/javascripts/discourse/templates/modal/avatar-selector.hbs +++ b/app/assets/javascripts/discourse/templates/modal/avatar-selector.hbs @@ -2,9 +2,9 @@ {{#if siteSettings.selectable_avatars_enabled}}
      {{#each selectableAvatars as |avatar|}} - + {{/each}}
      {{else}} diff --git a/app/assets/javascripts/discourse/templates/modal/group-bulk-add.hbs b/app/assets/javascripts/discourse/templates/modal/group-bulk-add.hbs index 26b0b94188f..495c4a16c01 100644 --- a/app/assets/javascripts/discourse/templates/modal/group-bulk-add.hbs +++ b/app/assets/javascripts/discourse/templates/modal/group-bulk-add.hbs @@ -14,7 +14,7 @@ {{/if}} {{else}}
      diff --git a/app/assets/javascripts/discourse/templates/modal/login.hbs b/app/assets/javascripts/discourse/templates/modal/login.hbs index 55748b56e7d..4a29ccd09a4 100644 --- a/app/assets/javascripts/discourse/templates/modal/login.hbs +++ b/app/assets/javascripts/discourse/templates/modal/login.hbs @@ -14,7 +14,7 @@ {{password-field value=loginPassword type="password" id="login-account-password" maxlength="200" capsLockOn=capsLockOn disabled=disableLoginFields}} - {{i18n 'forgot_password.action'}} + {{i18n 'forgot_password.action'}} diff --git a/app/assets/javascripts/discourse/templates/modal/second-factor-add-totp.hbs b/app/assets/javascripts/discourse/templates/modal/second-factor-add-totp.hbs index 32e3de51750..2b52edea7b6 100644 --- a/app/assets/javascripts/discourse/templates/modal/second-factor-add-totp.hbs +++ b/app/assets/javascripts/discourse/templates/modal/second-factor-add-totp.hbs @@ -26,7 +26,7 @@ {{#if showSecondFactorKey}} {{secondFactorKey}} {{else}} - {{i18n 'user.second_factor.show_key_description'}} + {{i18n 'user.second_factor.show_key_description'}} {{/if}}

      diff --git a/app/assets/javascripts/discourse/templates/preferences/account.hbs b/app/assets/javascripts/discourse/templates/preferences/account.hbs index f3aa6b8ad8f..0aef40f2a00 100644 --- a/app/assets/javascripts/discourse/templates/preferences/account.hbs +++ b/app/assets/javascripts/discourse/templates/preferences/account.hbs @@ -195,7 +195,7 @@
    {{#if canShowAllAuthTokens}} - + {{#if showAllAuthTokens}} {{d-icon "caret-up"}} {{i18n 'user.auth_tokens.show_few'}} {{else}} @@ -204,7 +204,7 @@ {{/if}} - {{d-icon "sign-out-alt"}} {{i18n 'user.auth_tokens.log_out_all'}} + {{d-icon "sign-out-alt"}} {{i18n 'user.auth_tokens.log_out_all'}}
    {{/if}} diff --git a/app/assets/javascripts/discourse/templates/tags/index.hbs b/app/assets/javascripts/discourse/templates/tags/index.hbs index 2740b1822f7..c71934d127e 100644 --- a/app/assets/javascripts/discourse/templates/tags/index.hbs +++ b/app/assets/javascripts/discourse/templates/tags/index.hbs @@ -13,8 +13,8 @@
    diff --git a/app/assets/javascripts/discourse/templates/user-private-messages-tags.hbs b/app/assets/javascripts/discourse/templates/user-private-messages-tags.hbs index 66c0e2f6d0c..5c331cac169 100644 --- a/app/assets/javascripts/discourse/templates/user-private-messages-tags.hbs +++ b/app/assets/javascripts/discourse/templates/user-private-messages-tags.hbs @@ -6,8 +6,16 @@
    diff --git a/app/assets/javascripts/discourse/templates/user.hbs b/app/assets/javascripts/discourse/templates/user.hbs index 161c6c0987a..a073738c35e 100644 --- a/app/assets/javascripts/discourse/templates/user.hbs +++ b/app/assets/javascripts/discourse/templates/user.hbs @@ -25,7 +25,7 @@ {{/if}} {{#if model.number_of_suspensions}}
    - + {{model.number_of_suspensions}}{{i18n 'user.staff_counters.suspensions'}}
    diff --git a/app/assets/stylesheets/common/admin/admin_base.scss b/app/assets/stylesheets/common/admin/admin_base.scss index a45e49ac604..2af39f5675f 100644 --- a/app/assets/stylesheets/common/admin/admin_base.scss +++ b/app/assets/stylesheets/common/admin/admin_base.scss @@ -956,6 +956,11 @@ table#user-badges { margin-right: 20px; } +a.inline-editable-field { + color: $primary; + cursor: pointer; +} + // Styles for subtabs in admin @import "common/admin/dashboard"; @import "common/admin/settings"; diff --git a/app/assets/stylesheets/common/admin/customize.scss b/app/assets/stylesheets/common/admin/customize.scss index 4ec13b753aa..86c1cb94425 100644 --- a/app/assets/stylesheets/common/admin/customize.scss +++ b/app/assets/stylesheets/common/admin/customize.scss @@ -186,26 +186,20 @@ border-bottom: 1px solid $primary-low; border-top: 1px solid $primary-low; border-right: 1px solid $primary-low; + display: flex; + .tab { - display: inline-block; - padding: 10px; + padding: 1em; width: 50%; box-sizing: border-box; text-align: center; - border-left: 1px solid $primary-low; &.active { - font-weight: bold; - color: $secondary; - background: $danger; + font-weight: 700; } - &:not(.active) { - cursor: pointer; - - &:hover { - background-color: $primary-very-low; - } + &:last-child { + border-left: 1px solid $primary-low; } } } @@ -297,6 +291,7 @@ .others-count, .others-count:hover { + color: $primary-high; text-decoration: underline; } } diff --git a/app/assets/stylesheets/common/base/alert.scss b/app/assets/stylesheets/common/base/alert.scss index 40541aab0bc..c367b3f8ea7 100644 --- a/app/assets/stylesheets/common/base/alert.scss +++ b/app/assets/stylesheets/common/base/alert.scss @@ -31,3 +31,7 @@ } } } + +a.alert.clickable { + display: flex; +}