framework/ember/app/templates/discussions.hbs

50 lines
1.4 KiB
Handlebars
Raw Normal View History

<div class="discussions-area">
<nav class="discussions-nav">
2015-01-03 19:21:47 +08:00
{{ui/controls/item-list items=view.sidebarItems}}
</nav>
<div class="discussions-results">
<div class="discussions-toolbar">
<div class="discussions-toolbar-view">
2015-01-03 19:21:47 +08:00
<span class="btn-group control-show">
{{#link-to (query-params show="discussions") class="btn btn-default"}}{{fa-icon "bars"}}{{/link-to}}
{{#link-to (query-params show="posts") class="btn btn-default"}}{{fa-icon "square-o"}}{{/link-to}}
2014-12-20 14:26:46 +08:00
</span>
2015-01-03 19:21:47 +08:00
{{ui/controls/select-input class="control-sort" content=sortOptions optionValuePath="content.sort" optionLabelPath="content.label" value=sort}}
2014-12-20 14:26:46 +08:00
</div>
<div class="discussions-toolbar-action">
2015-01-03 19:21:47 +08:00
{{#ui/controls/action-button class="control-markAsRead"}}{{fa-icon "check"}}{{/ui/controls/action-button}}
</div>
</div>
{{#if resultsLoading}}
2015-01-03 19:21:47 +08:00
{{ui/controls/loading-indicator size="small"}}
{{else}}
<ul class="discussions-list">
{{#each discussion in content}}
2015-01-07 14:52:34 +08:00
{{discussions/discussion-listing discussion=discussion searchQuery=searchQuery}}
{{/each}}
</ul>
{{#if moreResults}}
<div class="load-more">
{{#if loadingMore}}
2015-01-03 19:21:47 +08:00
{{ui/controls/loading-indicator size="small"}}
{{else}}
2015-01-03 19:21:47 +08:00
{{#ui/controls/action-button class="control-loadMore" action="loadMore"}}Load More{{/ui/controls/action-button}}
{{/if}}
</div>
{{/if}}
2014-12-20 14:26:46 +08:00
{{/if}}
</div>
2014-12-20 14:26:46 +08:00
</div>
<div class="discussion-area">
{{outlet}}
2014-12-20 14:26:46 +08:00
</div>