DEV: enforces block-indentation of ember-template-lint rules (#9408)

This commit is contained in:
Joffrey JAFFEUX 2020-04-13 17:17:20 +02:00 committed by GitHub
parent a863d8eecb
commit b66b277dc4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
101 changed files with 2543 additions and 2489 deletions

View File

@ -6,7 +6,7 @@ module.exports = {
// "eol-last": "always",
rules: {
"block-indentation": false,
"block-indentation": true,
"deprecated-render-helper": true,
"img-alt-attributes": false,
"linebreak-style": true,

View File

@ -2,9 +2,7 @@
<div class="row">
<div class="full-width">
<div class="admin-main-nav">
<ul class="nav nav-pills">
{{nav-item route='admin.dashboard' label='admin.dashboard.title'}}
{{#if currentUser.admin}}
{{nav-item route='adminSiteSettings' label='admin.site_settings.title'}}
@ -37,7 +35,6 @@
{{outlet}}
</div>
</div>
</div>
</div>
{{/admin-wrapper}}

View File

@ -12,9 +12,7 @@
class=(if target.edited 'edited' 'blank')
}}
{{#if target.error}}{{d-icon 'exclamation-triangle'}}{{/if}}
{{#if target.icon}}
{{d-icon target.icon}}
{{/if}}
{{#if target.icon}}{{d-icon target.icon}}{{/if}}
{{i18n (concat 'admin.customize.theme.' target.name)}}
{{/link-to}}
</li>
@ -25,13 +23,11 @@
<a {{action "toggleShowAdvanced"}}
class='no-text'
href
title={{i18n (concat "admin.customize.theme." (if showAdvanced "hide_advanced" "show_advanced"))}}
>
title={{i18n (concat "admin.customize.theme." (if showAdvanced "hide_advanced" "show_advanced"))}}>
{{d-icon (if showAdvanced "angle-double-left" "angle-double-right")}}
</a>
</li>
{{/if}}
<li class="spacer"></li>
<li>
<label>
@ -59,7 +55,6 @@
{{#if field.error}}{{d-icon 'exclamation-triangle'}}{{/if}}
{{#if field.icon}}{{d-icon field.icon}}{{/if}}
{{field.translatedName}}
{{/link-to}}
</li>
{{/each}}
@ -77,6 +72,7 @@
{{/if}}
</li>
{{/if}}
<li class='spacer'></li>
<li>
<a href {{action "toggleMaximize"}} class="no-text">

View File

@ -7,7 +7,8 @@
{{text-field
value=reason
class="silence-reason"
placeholderKey="admin.user.silence_reason_placeholder"}}
placeholderKey="admin.user.silence_reason_placeholder"
}}
</div>
<label>

View File

@ -7,18 +7,21 @@
class="btn-primary"
action=(action "save")
disabled=model.disableSave
label="admin.customize.save"}}
label="admin.customize.save"
}}
{{/unless}}
{{d-button
class="btn-default"
action=(action "copy" model)
icon="copy"
label="admin.customize.copy"}}
label="admin.customize.copy"
}}
{{d-button
class="btn-default"
action=(action "copyToClipboard" model)
icon="far-clipboard"
label="admin.customize.copy_to_clipboard"}}
label="admin.customize.copy_to_clipboard"
}}
{{#if model.theme_id}}
{{i18n "admin.customize.theme_owner"}}
{{#link-to "adminCustomizeThemes.show" model.theme_id}}{{model.theme_name}}{{/link-to}}
@ -27,7 +30,8 @@
action=(action "destroy")
class="btn-danger"
icon="far-trash-alt"
label="admin.customize.delete"}}
label="admin.customize.delete"
}}
{{/if}}
<span class="saving {{unless model.savingStatus 'hidden'}}">{{model.savingStatus}}</span>
</div>

View File

@ -6,7 +6,8 @@
class="filter-reports-input"
input=(action "filterReports" value="target.value")
placeholder=(i18n "admin.dashboard.filter_reports")
autofocus=true}}
autofocus=true
}}
</div>
<ul class="reports-list">
@ -14,7 +15,6 @@
<li class="report">
{{#link-to 'adminReports.show' report.type}}
<h3 class="report-title">{{report.title}}</h3>
{{#if report.description}}
<p class="report-description">
{{report.description}}

View File

@ -5,23 +5,21 @@
{{textarea name="email" value=email class="email-body"}}
{{d-button
action=(action "run")
label="admin.email.advanced_test.run"}}
label="admin.email.advanced_test.run"
}}
</div>
{{#conditional-loading-spinner condition=loading}}
{{#if format}}
<hr>
<div class="text">
<h3>{{i18n 'admin.email.advanced_test.text'}}</h3>
<pre class="full-reason">{{html-safe text}}</pre>
</div>
<hr>
<div class="elided">
<h3>{{i18n 'admin.email.advanced_test.elided'}}</h3>
<pre class="full-reason">{{html-safe elided}}</pre>
</div>
{{/if}}
{{/conditional-loading-spinner}}

View File

@ -13,8 +13,11 @@
<div class="toggle">
<label>{{i18n 'admin.email.format'}}</label>
{{#if showHtml}}
<span>{{i18n 'admin.email.html'}}</span> | <a href
{{action "toggleShowHtml"}}>{{i18n 'admin.email.text'}}</a>
<span>{{i18n 'admin.email.html'}}</span>
|
<a href {{action "toggleShowHtml"}}>
{{i18n 'admin.email.text'}}
</a>
{{else}}
<a href {{action "toggleShowHtml"}}>{{i18n 'admin.email.html'}}</a> |
<span>{{i18n 'admin.email.text'}}</span>

View File

@ -41,10 +41,10 @@
{{d-button class="btn-default" action=(action "exportStaffActionLogs") label="admin.export_csv.button_text" icon="download"}}
</div>
<div class="clearfix"></div>
{{#staff-actions}}
{{#load-more selector=".staff-logs tr" action=(action "loadMore")}}
{{#if model.content}}
<table class='table staff-logs grid'>
@ -108,5 +108,4 @@
{{i18n 'search.no_results'}}
{{/if}}
{{/load-more}}
{{/staff-actions}}

View File

@ -29,8 +29,10 @@
{{plugin.name}}
{{/if}}
</td>
<td class="version"> <div class="label">{{i18n "admin.plugins.version"}}</div>
{{plugin.version}}</td>
<td class="version">
<div class="label">{{i18n "admin.plugins.version"}}</div>
{{plugin.version}}
</td>
<td class="col-enabled">
<div class="label">{{i18n "admin.plugins.enabled"}}</div>
{{#if plugin.enabled_setting}}

View File

@ -1,16 +1,16 @@
<div class='admin-controls'>
<div class='controls'>
{{d-button action=(action "toggleMenu") class="menu-toggle" icon="bars"}}
{{#if currentUser.admin}}
{{d-button label="admin.plugins.change_settings"
{{d-button
label="admin.plugins.change_settings"
icon="cog"
class="btn-default settings-button"
action=(route-action "showSettings")}}
action=(route-action "showSettings")
}}
{{/if}}
</div>
</div>
<div class="admin-nav pull-left">

View File

@ -117,31 +117,42 @@
{{#if model.tl3Requirements.requirements_lost}}
{{! tl implicitly not locked }}
{{#if model.tl3Requirements.on_grace_period}}
{{d-icon "times"}} {{i18n 'admin.user.tl3_requirements.on_grace_period'}}
{{else}} {{! not on grace period }}
{{d-icon "times"}} {{i18n 'admin.user.tl3_requirements.does_not_qualify'}}
{{d-icon "times"}}
{{i18n 'admin.user.tl3_requirements.on_grace_period'}}
{{else}}
{{! not on grace period }}
{{d-icon "times"}}
{{i18n 'admin.user.tl3_requirements.does_not_qualify'}}
{{i18n 'admin.user.tl3_requirements.will_be_demoted'}}
{{/if}}
{{else}} {{! requirements not lost - remains tl3 }}
{{else}}
{{! requirements not lost - remains tl3 }}
{{#if model.tl3Requirements.trust_level_locked}}
{{d-icon "lock"}} {{i18n 'admin.user.tl3_requirements.locked_will_not_be_demoted'}}
{{else}} {{! tl not locked }}
{{d-icon "check"}} {{i18n 'admin.user.tl3_requirements.qualifies'}}
{{d-icon "lock"}}
{{i18n 'admin.user.tl3_requirements.locked_will_not_be_demoted'}}
{{else}}
{{! tl not locked }}
{{d-icon "check"}}
{{i18n 'admin.user.tl3_requirements.qualifies'}}
{{#if model.tl3Requirements.on_grace_period}}
{{i18n 'admin.user.tl3_requirements.on_grace_period'}}
{{/if}}
{{/if}}
{{/if}}
{{else}} {{! is not tl3 }}
{{else}}
{{! is not tl3 }}
{{#if model.tl3Requirements.requirements_met}}
{{! met & not tl3 - will be promoted}}
{{d-icon "check"}} {{i18n 'admin.user.tl3_requirements.qualifies'}}
{{d-icon "check"}}
{{i18n 'admin.user.tl3_requirements.qualifies'}}
{{i18n 'admin.user.tl3_requirements.will_be_promoted'}}
{{else}} {{! requirements not met - remains regular }}
{{#if model.tl3Requirements.trust_level_locked}}
{{d-icon "lock"}} {{i18n 'admin.user.tl3_requirements.locked_will_not_be_promoted'}}
{{else}}
{{d-icon "times"}} {{i18n 'admin.user.tl3_requirements.does_not_qualify'}}
{{! requirements not met - remains regular }}
{{#if model.tl3Requirements.trust_level_locked}}
{{d-icon "lock"}}
{{i18n 'admin.user.tl3_requirements.locked_will_not_be_promoted'}}
{{else}}
{{d-icon "times"}}
{{/if}}
{{/if}}
{{/if}}

View File

@ -5,7 +5,6 @@
{{else}}
{{i18n 'upload'}}
{{/if}}
<input class="hidden-upload-field" disabled={{uploading}} type="file" accept="image/*">
</label>

View File

@ -8,7 +8,8 @@
{{/if}}
{{#if topics}}
{{topic-list showPosters=showPosters
{{topic-list
showPosters=showPosters
hideCategory=hideCategory
topics=topics
expandExcerpts=expandExcerpts
@ -18,8 +19,8 @@
skipHeader=skipHeader
tagsForUser=tagsForUser
onScroll=onScroll
scrollOnLoad=scrollOnLoad}}
scrollOnLoad=scrollOnLoad
}}
{{else}}
{{#unless loadingMore}}
<div class='alert alert-info'>

View File

@ -5,13 +5,14 @@
<a href={{c.url}}>
{{#unless c.isMuted}}
{{#if c.uploaded_logo.url}}
{{cdn-img src=c.uploaded_logo.url
{{cdn-img
src=c.uploaded_logo.url
class="logo"
width=c.uploaded_logo.width
height=c.uploaded_logo.height}}
height=c.uploaded_logo.height
}}
{{/if}}
{{/unless}}
<h3>
{{category-title-before category=c}}
{{#if c.read_restricted}}

View File

@ -9,7 +9,8 @@
src=c.uploaded_logo.url
class="logo"
width=c.uploaded_logo.width
height=c.uploaded_logo.height}}
height=c.uploaded_logo.height
}}
{{/if}}
</div>
{{/unless}}

View File

@ -1,5 +1,6 @@
{{#if showSelector}}
{{user-selector topicId=topicId
{{user-selector
topicId=topicId
onChangeCallback=(action "triggerResize")
id="private-message-users"
includeMessageableGroups='true'
@ -8,7 +9,8 @@
usernames=usernames
hasGroups=hasGroups
allowEmails='true'
autocomplete="discourse"}}
autocomplete="discourse"
}}
{{else}}
<a href {{action "toggleSelector"}}>
<div class='ac-wrap composer-user-selector-limited'>

View File

@ -77,13 +77,10 @@
{{i18n "category.all_topics_wiki"}}
</label>
</section>
</section>
<section>
<h3>{{i18n 'category.settings_sections.moderation'}}</h3>
{{#if siteSettings.enable_category_group_review}}
<section class="field">
<label for="reviewable-by-group">
@ -93,7 +90,8 @@
groupFinder=groupFinder
single="true"
groupNames=category.reviewable_by_group_name
placeholderKey="category.review_group_name"}}
placeholderKey="category.review_group_name"
}}
</section>
{{/if}}
@ -139,11 +137,9 @@
</label>
{{text-field value=category.custom_fields.num_auto_bump_daily id="category-number-daily-bump" type="number"}}
</section>
</section>
<section>
<h3>{{i18n "category.settings_sections.appearance"}}</h3>
<section class="field default-view-field">
@ -200,7 +196,6 @@
{{/unless}}
</div>
</section>
{{#if isParentCategory}}
<section class="field show-subcategory-list-field">
<label>
@ -226,7 +221,6 @@
}}
</section>
{{/if}}
</section>
<section>
@ -264,7 +258,6 @@
<a href={{get-url '/admin/site_settings/category/email'}}>{{i18n 'category.email_in_disabled_click'}}</a>
</section>
{{/unless}}
</section>
{{plugin-outlet name="category-custom-settings" args=(hash category=category) connectorTagName="" tagName="section"}}

View File

@ -1,6 +1,5 @@
{{#if visible}}
<div class="card-content">
<div class="card-row first-row">
<div class="group-card-avatar">
<a href={{groupPath}} {{action "showGroup" group}} class="card-huge-avatar">
@ -8,7 +7,8 @@
flairURL=group.flair_url
flairBgColor=group.flair_bg_color
flairColor=group.flair_color
groupName=group.name}}
groupName=group.name
}}
</a>
</div>
<div class="names">
@ -27,7 +27,8 @@
<li>
{{group-membership-button
model=group
showLogin=(route-action "showLogin")}}
showLogin=(route-action "showLogin")
}}
</li>
{{#if group.messageable}}
<li>
@ -35,7 +36,8 @@
action=(action "messageGroup")
class="btn-primary group-message-button inline"
icon="envelope"
label="groups.message"}}
label="groups.message"
}}
</li>
{{/if}}
</ul>
@ -74,13 +76,12 @@
<a href {{action 'showUser' user}} class="card-tiny-avatar">{{bound-avatar user "tiny"}}</a>
{{/each}}
{{#if showMoreMembers}}
<a href={{groupPath}} {{action "showGroup" group}} class="more-members-link"><span
class="more-members-count">+{{moreMembersCount}}
{{i18n "more"}}</span></a>
<a href={{groupPath}} {{action "showGroup" group}} class="more-members-link">
<span class="more-members-count">+{{moreMembersCount}}{{i18n "more"}}</span>
</a>
{{/if}}
</div>
</div>
{{/if}}
</div>
{{/if}}

View File

@ -1,8 +1,8 @@
<div class='control-group buttons'>
{{#d-button action=(action "save")
disabled=saving
class='btn btn-primary group-manage-save'}}
class='btn btn-primary group-manage-save'
}}
{{savingText}}
{{/d-button}}

View File

@ -19,7 +19,6 @@
</div>
{{/if}}
</div>
</div>
<div class='excerpt'>

View File

@ -42,7 +42,8 @@
{{d-button
icon="address-book"
action=(action "searchContact")
class="btn-primary open-contact-picker"}}
class="btn-primary open-contact-picker"
}}
{{/if}}
</div>
</div>

View File

@ -19,11 +19,9 @@
{{/user-link}}
</td>
<td>{{format-date rh.created_at format="medium"}}</td>
</tr>
{{/unless}}
{{/each}}
</tbody>
</table>
{{/if}}

View File

@ -10,8 +10,10 @@
<nav id='topic-progress' title={{i18n 'topic.progress.title'}} class={{if hideProgress 'hidden'}}>
<div class='nums'>
<h4>{{progressPosition}}</h4><span class={{if hugeNumberOfPosts 'hidden'}}>
<h4>{{progressPosition}}</h4>
<span class={{if hugeNumberOfPosts 'hidden'}}>
<span>/</span>
<h4>{{postStream.filteredPostsCount}}</h4></span>
<h4>{{postStream.filteredPostsCount}}</h4>
</span>
</div>
</nav>

View File

@ -153,8 +153,10 @@
<div class="card-row">
<div class="location-and-website">
{{#if user.location}}
<span class='location'>{{d-icon "map-marker-alt"}}
<span>{{user.location}}</span></span>
<span class='location'>
{{d-icon "map-marker-alt"}}
<span>{{user.location}}</span>
</span>
{{/if}}
{{#if user.website_name}}
<span class='website-name'>

View File

@ -1,5 +1,10 @@
<label class="control-label" for={{concat 'user-' elementId}}>{{html-safe field.name}} {{#if field.required}}<span class='required'>*</span>{{/if}}
<label class="control-label" for={{concat 'user-' elementId}}>
{{html-safe field.name}}
{{#if field.required}}
<span class='required'>*</span>
{{/if}}
</label>
<div class='controls'>
{{combo-box
id=(concat 'user-' elementId)

View File

@ -46,7 +46,8 @@
</p>
{{#each item.children as |child|}}
<div class='user-stream-item-actions child-actions'>{{!-- DEPRECATED: 'child-actions' class --}}
{{!-- DEPRECATED: 'child-actions' class --}}
<div class='user-stream-item-actions child-actions'>
{{d-icon child.icon class="icon"}}
{{#each child.items as |grandChild|}}
{{#if grandChild.removableBookmark}}
@ -54,7 +55,8 @@
class="btn-default remove-bookmark"
action=(action removeBookmark grandChild)
icon="times"
label="bookmarks.remove"}}
label="bookmarks.remove"
}}
{{else}}
<a href={{grandChild.userUrl}} data-user-card={{grandChild.username}} class='avatar-link'><div class='avatar-wrapper'>{{avatar grandChild imageSize="tiny" extraClasses="actor" ignoreTitle="true" avatarTemplatePath="acting_avatar_template"}}</div></a>
{{#if grandChild.edit_reason}} &mdash; <span class="edit-reason">{{grandChild.edit_reason}}</span>{{/if}}

View File

@ -1,11 +1,12 @@
<section class="user-content">
<div class="group-members-actions">
{{#if model.can_see_members}}
{{text-field value=filterInput
{{text-field
value=filterInput
placeholderKey=filterPlaceholder
autocomplete="discourse"
class="group-username-filter no-blur"}}
class="group-username-filter no-blur"
}}
{{/if}}
<div class="group-members-manage">

View File

@ -1,9 +1,11 @@
<section class="user-content">
<div class="group-members-actions">
{{text-field value=filterInput
{{text-field
value=filterInput
placeholderKey=filterPlaceholder
class="group-username-filter no-blur"}}
class="group-username-filter no-blur"
}}
</div>
{{#if hasRequesters}}

View File

@ -59,7 +59,6 @@
{{group-navigation group=model currentPath=currentPath tabs=tabs}}
</div>
</section>
{{outlet}}
</div>
</div>

View File

@ -1,6 +1,5 @@
<section class="user-secondary-navigation">
{{#mobile-nav class='messages-nav' desktopClass='nav-stacked action-list' currentPath=router._router.currentPath}}
<li>
{{#link-to 'group.messages.inbox' model.name}}
{{i18n 'user.messages.inbox'}}

View File

@ -1,5 +1,4 @@
<div class="container invites-show clearfix">
<h2>{{welcomeTitle}}</h2>
<div class="two-col">
@ -10,12 +9,15 @@
<div class="col-form">
{{#if successMessage}}
<br><br>
<div class='alert alert-info'><p>{{html-safe successMessage}}</p></div>
<div class='alert alert-info'>
<p>{{html-safe successMessage}}</p>
</div>
{{else}}
<p>{{i18n 'invites.invited_by'}}</p>
<p>{{user-info user=invitedBy}}</p>
<p>{{html-safe yourEmailMessage}}
<p>
{{html-safe yourEmailMessage}}
{{#if externalAuthsEnabled}}
{{i18n 'invites.social_login_available'}}
{{/if}}
@ -44,7 +46,8 @@
<div class="instructions">
{{passwordInstructions}} {{i18n 'invites.optional_description'}}
<div class="caps-lock-warning {{unless capsLockOn 'invisible'}}">
{{d-icon "exclamation-triangle"}} {{i18n 'login.caps_lock_warning'}}</div>
{{d-icon "exclamation-triangle"}} {{i18n 'login.caps_lock_warning'}}
</div>
</div>
</div>
@ -61,7 +64,8 @@
action=(action "submit")
type="submit"
disabled=submitDisabled
label="invites.accept_invite"}}
label="invites.accept_invite"
}}
{{#if errorMessage}}
<br><br>

View File

@ -16,9 +16,11 @@
<div class='main-link'>
{{topic-status topic=t}}
{{topic-link t}}
{{raw "list/unread-indicator" includeUnreadIndicator=showUnreadIndicator
{{raw "list/unread-indicator"
includeUnreadIndicator=showUnreadIndicator
topicId=t.id
unreadClass=(if t.unread_by_group_member "" "read")}}
unreadClass=(if t.unread_by_group_member "" "read")
}}
{{#if t.unseen}}
<span class="badge-notification new-topic"></span>
{{/if}}
@ -26,10 +28,14 @@
<div class="topic-excerpt">
{{html-safe t.excerpt}}
{{#if t.excerptTruncated}}
{{#unless t.canClearPin}}<a href={{t.url}}>{{i18n 'read_more'}}</a>{{/unless}}
{{#unless t.canClearPin}}
<a href={{t.url}}>{{i18n 'read_more'}}</a>
{{/unless}}
{{/if}}
{{#if t.canClearPin}}
<a href {{action "clearPin" t}} title={{i18n 'topic.clear_pin.help'}}>{{i18n 'topic.clear_pin.title'}}</a>
<a href {{action "clearPin" t}} title={{i18n 'topic.clear_pin.help'}}>
{{i18n 'topic.clear_pin.title'}}
</a>
{{/if}}
</div>
{{/if}}

View File

@ -9,7 +9,6 @@
{{category-title-link category=c}}
</th>
</tr>
{{#unless c.isMuted}}
{{#if c.description_excerpt}}
<tr class="category-description">
@ -18,13 +17,11 @@
</td>
</tr>
{{/if}}
{{#if showTopics}}
{{#each c.topics as |t|}}
{{mobile-category-topic topic=t}}
{{/each}}
{{/if}}
{{#if c.isGrandParent}}
{{#each c.subcategories as |subcategory|}}
<tr data-category-id={{c.id}} class='subcategory-list-item category' style={{border-color subcategory.color}}>
@ -61,16 +58,22 @@
</tbody>
</table>
<footer class="clearfix">
<figure title={{i18n 'all_time_desc'}}>{{number c.topics_all_time}} <figcaption>{{i18n 'all_time'}}</figcaption></figure>
<figure title={{i18n 'all_time_desc'}}>
{{number c.topics_all_time}}
<figcaption>{{i18n 'all_time'}}</figcaption>
</figure>
{{#if c.pickMonth}}
<figure title={{i18n 'month_desc'}}>{{number c.topics_month}} <figcaption>/ {{i18n 'month'}}</figcaption></figure>
<figure title={{i18n 'month_desc'}}>
{{number c.topics_month}}
<figcaption>/ {{i18n 'month'}}</figcaption>
</figure>
{{/if}}
{{#if c.pickWeek}}
<figure title={{i18n 'week_desc'}}>{{number c.topics_week}} <figcaption>/ {{i18n 'week'}}</figcaption></figure>
<figure title={{i18n 'week_desc'}}>
{{number c.topics_week}}
<figcaption>/ {{i18n 'week'}}</figcaption>
</figure>
{{/if}}
</footer>
</div>
{{/each}}

View File

@ -1,8 +1,10 @@
<section class="user-content">
{{text-field value=filterInput
{{text-field
value=filterInput
placeholderKey=filterPlaceholder
autocomplete="discourse"
class="group-username-filter no-blur"}}
class="group-username-filter no-blur"
}}
<div class="group-members-manage">
{{#if canManageGroup}}
@ -16,7 +18,8 @@
icon="plus"
label="groups.add_members.title"
class="group-members-add"
action=(route-action "showAddMembersModal")}}
action=(route-action "showAddMembersModal")
}}
{{/if}}
{{/if}}
</div>

View File

@ -55,13 +55,17 @@
</tr>
{{/if}}
{{plugin-outlet name="create-account-before-password"
{{plugin-outlet
name="create-account-before-password"
noTags=true
args=(hash accountName=accountName
args=(hash
accountName=accountName
accountUsername=accountUsername
accountPassword=accountPassword
userFields=userFields
authOptions=authOptions)}}
authOptions=authOptions
)
}}
{{#if passwordRequired}}
<tr class="input">
@ -76,7 +80,8 @@
<td>
<label>{{passwordInstructions}}</label>
<div class="caps-lock-warning {{unless capsLockOn 'hidden'}}">
{{d-icon "exclamation-triangle"}} {{i18n 'login.caps_lock_warning'}}</div>
{{d-icon "exclamation-triangle"}} {{i18n 'login.caps_lock_warning'}}
</div>
</td>
</tr>
{{/if}}
@ -95,17 +100,20 @@
<td>
{{input value=inviteCode id="inviteCode"}}
</td>
<td><label>{{i18n 'user.invite_code.instructions'}}</label></td>
</tr>
{{/if}}
{{plugin-outlet name="create-account-after-password"
{{plugin-outlet
name="create-account-after-password"
noTags=true
args=(hash accountName=accountName
args=(hash
accountName=accountName
accountUsername=accountUsername
accountPassword=accountPassword
userFields=userFields)}}
userFields=userFields
)
}}
</tbody>
</table>
@ -116,11 +124,9 @@
{{/each}}
</div>
{{/if}}
</form>
</div>
{{/if}}
{{/d-modal-body}}
{{#if showCreateForm}}
@ -129,7 +135,8 @@
class="btn-large btn-primary"
action=(action "createAccount")
disabled=submitDisabled
label="create_account.title"}}
label="create_account.title"
}}
{{#conditional-loading-spinner condition=formSubmitted size="small"}}
{{#d-button class="btn-large" id="login-link" action=(route-action "showLogin")}}
@ -141,7 +148,6 @@
</div>
{{plugin-outlet name="create-account-after-modal-footer" tagName=""}}
{{/if}}
{{/unless}}
{{/create-account}}

View File

@ -1,13 +1,15 @@
{{#d-modal-body class="flag-modal-body" title=title}}
<form>
{{#flag-selection nameKey=selected.name_key flags=flagsAvailable as |f|}}
{{flag-action-type flag=f
{{flag-action-type
flag=f
message=message
isWarning=isWarning
selectedFlag=selected
username=model.username
staffFlagsAvailable=staffFlagsAvailable
changePostActionType=(action "changePostActionType")}}
changePostActionType=(action "changePostActionType")
}}
{{/flag-selection}}
</form>
{{/d-modal-body}}
@ -19,7 +21,8 @@
disabled=submitDisabled
title="flagging.submit_tooltip"
icon=submitIcon
label=submitLabel}}
label=submitLabel
}}
{{#if canSendWarning}}
{{d-button
@ -27,7 +30,8 @@
action=(action "createFlagAsWarning")
disabled=submitDisabled
icon="exclamation-triangle"
label="flagging.official_warning"}}
label="flagging.official_warning"
}}
{{/if}}
{{#if canTakeAction}}
@ -37,7 +41,8 @@
disabled=submitDisabled
title="flagging.take_action_tooltip"
icon="gavel"
label="flagging.take_action"}}
label="flagging.take_action"
}}
{{/if}}
{{#if showDeleteSpammer}}
@ -46,6 +51,7 @@
action=(action "deleteSpammer")
disabled=submitDisabled
icon="exclamation-triangle"
label="flagging.delete_spammer"}}
label="flagging.delete_spammer"
}}
{{/if}}
</div>

View File

@ -5,11 +5,14 @@
<div class='second-factor instructions'>
{{i18n 'user.second_factor.security_key.edit_description'}}
</div>
{{d-button action=(action "editSecurityKey")
{{d-button
action=(action "editSecurityKey")
class="btn-primary"
label="user.second_factor.security_key.edit"}}
{{d-button action=(action "disableSecurityKey")
label="user.second_factor.security_key.edit"
}}
{{d-button
action=(action "disableSecurityKey")
class="btn-danger"
label="user.second_factor.security_key.delete"}}
label="user.second_factor.security_key.delete"
}}
{{/d-modal-body}}

View File

@ -5,11 +5,14 @@
<div class='second-factor instructions'>
{{i18n 'user.second_factor.edit_description'}}
</div>
{{d-button action=(action "editSecondFactor")
{{d-button
action=(action "editSecondFactor")
class="btn-primary"
label="user.second_factor.edit"}}
{{d-button action=(action "disableSecondFactor")
label="user.second_factor.edit"
}}
{{d-button
action=(action "disableSecondFactor")
class="btn-danger"
label="user.second_factor.disable"}}
label="user.second_factor.disable"
}}
{{/d-modal-body}}

View File

@ -53,7 +53,8 @@
<div class="instructions">
<div class="caps-lock-warning {{unless capsLockOn 'invisible'}}">
{{d-icon "exclamation-triangle"}} {{i18n 'login.caps_lock_warning'}}</div>
{{d-icon "exclamation-triangle"}} {{i18n 'login.caps_lock_warning'}}
</div>
</div>
{{d-button action=(action "submit") class='btn-primary' label='user.change_password.set_password' type='submit'}}

View File

@ -1,7 +1,6 @@
<section class='user-preferences solo-preference second-factor'>
{{#conditional-loading-spinner condition=loading}}
<form class="form-horizontal">
{{#if showEnforcedNotice}}
<div class="control-group">
<div class="controls">

View File

@ -4,7 +4,8 @@
<span class='static'>{{model.username}}</span>
{{#if model.can_edit_username}}
{{#link-to "preferences.username" class="btn btn-default btn-small btn-icon pad-left no-text"}}
{{d-icon "pencil-alt"}} {{/link-to}}
{{d-icon "pencil-alt"}}
{{/link-to}}
{{/if}}
</div>
{{#if siteSettings.enable_mentions}}

View File

@ -67,7 +67,9 @@
<label class="control-label">{{i18n 'user.featured_topic'}}</label>
{{#if model.featured_topic}}
<label class="featured-topic-link">
{{#link-to "topic" model.featured_topic.slug model.featured_topic.id}}{{html-safe (replace-emoji model.featured_topic.fancy_title)}}{{/link-to}}
{{#link-to "topic" model.featured_topic.slug model.featured_topic.id}}
{{html-safe (replace-emoji model.featured_topic.fancy_title)}}
{{/link-to}}
</label>
{{/if}}

View File

@ -1,6 +1,5 @@
{{#if siteSettings.tagging_enabled}}
<div class="control-group tag-notifications">
<label class="control-label">{{i18n 'user.tag_settings'}}</label>
<div class="controls tracking-controls">
@ -11,8 +10,10 @@
filterPlaceholder="select_kit.filter_placeholder"
allowCreate=false
everyTag=true
unlimitedTagCount=true}}
unlimitedTagCount=true
}}
</div>
<div class="instructions">{{i18n 'user.watched_tags_instructions'}}</div>
<div class="controls tracking-controls">
@ -25,6 +26,7 @@
everyTag=true
unlimitedTagCount=true}}
</div>
<div class="instructions">{{i18n 'user.tracked_tags_instructions'}}</div>
<div class="controls tracking-controls">
@ -37,7 +39,10 @@
everyTag=true
unlimitedTagCount=true}}
</div>
<div class="instructions">{{i18n 'user.watched_first_post_tags_instructions'}}</div>
<div class="instructions">
{{i18n 'user.watched_first_post_tags_instructions'}}
</div>
<div class="controls tracking-controls">
<label>{{d-icon "d-muted" class="icon muted"}} {{i18n 'user.muted_tags'}}</label>
@ -50,7 +55,6 @@
unlimitedTagCount=true}}
</div>
<div class="instructions">{{i18n 'user.muted_tags_instructions'}}</div>
</div>
{{plugin-outlet name="user-preferences-tags" args=(hash model=model save=(action "save"))}}
@ -60,5 +64,4 @@
{{plugin-outlet name="user-custom-controls" args=(hash model=model)}}
{{save-controls model=model action=(action "save") saved=saved}}
{{/if}}

View File

@ -5,13 +5,13 @@
<div class="list-controls">
<div class="container">
<section class="navigation-container">
{{#if showTagFilter}}
{{bread-crumbs categories=categories
{{bread-crumbs
categories=categories
category=category
tagId=tag.id
noSubcategories=noSubcategories}}
noSubcategories=noSubcategories
}}
{{navigation-bar navItems=navItems filterMode=filterMode}}
{{else}}
<h2 class="tag-show-heading">
@ -38,7 +38,8 @@
canCreateTopic=canCreateTopic
disabled=createTopicDisabled
label=createTopicLabel
action=(route-action "createTopic")}}
action=(route-action "createTopic")
}}
{{#if showToggleInfo}}
{{d-button icon="tag" label="tagging.info" action=(action "toggleInfo") id="show-tag-info"}}
@ -52,6 +53,7 @@
{{/if}}
{{plugin-outlet name="discovery-list-container-top"}}
<div class="container list-container">
<div class="row">
<div class="full-width">
@ -60,8 +62,8 @@
{{#if list.topics}}
{{#discovery-topics-list model=list refresh=(action "refresh")}}
{{bulk-select-button selected=selected action=(action "refresh")}}
{{topic-list topics=list.topics
{{topic-list
topics=list.topics
canBulkSelect=canBulkSelect
toggleBulkSelect=(action "toggleBulkSelect")
bulkSelectEnabled=bulkSelectEnabled
@ -69,8 +71,8 @@
showPosters=true
order=order
ascending=ascending
changeSort=(action "changeSort")}}
changeSort=(action "changeSort")
}}
{{/discovery-topics-list}}
{{else}}
<footer class='topic-list-bottom'>

View File

@ -1,7 +1,6 @@
{{plugin-outlet name="above-user-profile" tagName='' args=(hash model=model)}}
<div class="container {{if viewingSelf 'viewing-self'}}">
{{#d-section class="user-main"}}
<section class="{{if collapsedInfo 'collapsed-info'}} about {{if hasProfileBackgroundUrl 'has-background' 'no-background'}}" >
{{#unless collapsedInfo}}
{{#if showStaffCounters}}
@ -45,7 +44,6 @@
{{/if}}
<div class="user-profile-image" style={{model.profileBackgroundUrl}}></div>
{{/unless}}
<div class='details'>
<div class='primary'>
{{user-profile-avatar user=model tagName=""}}
@ -138,7 +136,8 @@
{{else}}
{{i18n 'user.suspended_notice' date=model.suspendedTillDate}}
{{/if}}
</b><br>
</b>
<br>
{{#if model.suspend_reason}}
<b>{{i18n 'user.suspended_reason'}}</b> {{model.suspend_reason}}
{{/if}}
@ -201,7 +200,6 @@
</dd>
</div>
{{/if}}
{{#if model.displayGroups}}
<div><dt class="groups">{{i18n 'groups.title' count=model.displayGroups.length}}</dt>
<dd class='groups'>
@ -224,12 +222,8 @@
</div>
{{/unless}}
</div>
</section>
<div class='user-content-wrapper'>
<section class="user-primary-navigation">
{{#mobile-nav class='main-nav' desktopClass="nav nav-pills user-nav" currentPath=currentPath}}
{{#unless model.profile_hidden}}
@ -258,9 +252,7 @@
{{/if}}
{{/mobile-nav}}
</section>
{{outlet}}
</div>
{{/d-section}}
</div>

View File

@ -28,11 +28,12 @@
</li>
{{/if}}
{{/if}}
{{plugin-outlet name="user-activity-bottom"
{{plugin-outlet
name="user-activity-bottom"
connectorTagName='li'
args=(hash model=model)}}
args=(hash model=model)
}}
{{/mobile-nav}}
{{/d-section}}
{{#if canDownloadPosts}}
<section class='user-additional-controls'>

View File

@ -56,9 +56,7 @@
{{/d-section}}
<section class='user-content'>
<div class="list-actions">
{{#unless site.mobileView}}
{{#if showToggleBulkSelect}}
{{d-button
@ -107,6 +105,5 @@
}}
{{/if}}
</div>
{{outlet}}
</section>

View File

@ -33,12 +33,14 @@
{{#if model}}
<section class="user-additional-controls">
{{d-button title='user.dismiss_notifications_tooltip'
{{d-button
title='user.dismiss_notifications_tooltip'
class='btn btn-default dismiss-notifications'
action=(action "resetNew")
label='user.dismiss_notifications'
icon='check'
disabled=allNotificationsRead}}
disabled=allNotificationsRead
}}
</section>
{{/if}}

View File

@ -1,7 +1,8 @@
<label>
{{input type="checkbox"
{{input
type="checkbox"
class="wizard-checkbox"
checked=field.value}}
checked=field.value
}}
{{field.placeholder}}
</label>