discourse/app/assets/javascripts/discourse/templates/poster-expansion.js.handlebars
2014-08-26 00:37:10 -07:00

56 lines
1.9 KiB
Handlebars

{{#if username}}
{{#link-to 'user' user}}{{bound-avatar avatar "huge"}}{{/link-to}}
<div class="names">
<h1 {{bind-attr class="staff new_user"}}>
{{#link-to 'user' user}}{{username}}{{/link-to}}
</h1>
{{#if showName}}
<h2>{{#link-to 'user' user}}{{name}}{{/link-to}}</h2>
{{/if}}
</div>
{{#if showBadges}}
<div class="badge-section">
{{#each user.featured_user_badges}}
{{user-badge badge=badge}}
{{/each}}
{{#if showMoreBadges}}
{{#link-to 'user.badges' user class="btn more-user-badges"}}
{{i18n badges.more_badges count=moreBadgesCount}}
{{/link-to}}
{{/if}}
</div>
{{/if}}
{{#if user}}
<div class="metadata">
{{#if user.location}}<h3><i class="fa fa-map-marker"></i> {{user.location}}</h3>{{/if}}
<h3>{{i18n last_post}} {{date path="user.last_posted_at" leaveAgo="true"}}</h3>
<h3>{{i18n joined}} {{date path="user.created_at" leaveAgo="true"}}</h3>
{{groups-list groups=user.custom_groups}}
</div>
<div class='bottom'>
{{#if user.bio_cooked}}<div class='bio'>{{{user.bio_cooked}}}</div>{{/if}}
{{#if user.can_send_private_message_to_user}}
<button class='btn btn-primary' {{action composePrivateMessage user}}><i class='fa fa-envelope'></i>{{i18n user.private_message}}</button>
{{/if}}
{{#link-to 'user' user class="btn"}}<i class='fa fa-user'></i>{{i18n user.profile}}{{/link-to}}
{{#if showFilter}}
<button class='btn' {{action togglePosts user}}><i class='fa fa-filter'></i>{{i18n topic.filter_to username="username" post_count="participant.post_count"}}</button>
{{/if}}
{{#if hasUserFilters}}
<button class='btn' {{action cancelFilter}}><i class='fa fa-times'></i>{{i18n topic.filters.cancel}}</button>
{{/if}}
</div>
{{else}}
<p class='loading'>{{i18n loading}}</p>
{{/if}}
{{/if}}