forked from evoko/zendesk-theme
-
Notifications
You must be signed in to change notification settings - Fork 1
/
community_post_list_page.hbs
141 lines (129 loc) · 4.24 KB
/
community_post_list_page.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
<section class="section hero community-hero">
<div class="hero-inner">
{{search submit=false class='search search-full' scoped=settings.scoped_community_search}}
</div>
</section>
<div class="container">
<nav class="sub-nav">
{{breadcrumbs}}
</nav>
<header class="page-header community-header">
<h4>
<span class="dropdown">
<button class="dropdown-toggle" aria-haspopup="true">
{{t 'all_posts'}}
</button>
<span class="dropdown-menu" role="menu">
{{#link 'topics' role='menuitem'}}
{{t 'show_topics'}}
{{/link}}
{{#link 'posts' role='menuitem' selected='true'}}
{{t 'show_all_posts'}}
{{/link}}
</span>
</span>
</h4>
<span class="post-to-community">
{{link 'new_post' role='button' class='button-large'}}
</span>
</header>
<div class="topic-header">
<span class="topic-filters">
<span class="dropdown">
<button class="dropdown-toggle" aria-haspopup="true">
{{current_filter.label}}
</button>
<span class="dropdown-menu" role="menu">
{{#each filters}}
<a href="{{url}}" aria-selected="{{selected}}" role="menuitem">
{{name}}
</a>
{{/each}}
</span>
</span>
<span class="dropdown">
<button class="dropdown-toggle" aria-haspopup="true">
{{current_sorter.label}}
</button>
<span class="dropdown-menu" role="menu">
{{#each sorters}}
<a href="{{url}}" aria-selected="{{selected}}" role="menuitem">
{{name}}
</a>
{{/each}}
</span>
</span>
</span>
</div>
<ul class="posts-list striped-list">
{{#unless posts}}
<div class="no-posts-with-filter">
{{t 'no_posts_with_filter'}}
</div>
{{/unless}}
{{#each posts}}
<li>
<div class="striped-list-item {{#if featured}}post-featured{{/if}}">
<span class="striped-list-info">
<a href="{{url}}" title="{{title}}" class="striped-list-title">{{title}}</a>
<span class="post-overview-item">
{{#if pinned}}
<span class="status-label status-label-pinned">{{t 'pinned'}}</span>
{{/if}}
{{#if featured}}
<span class="status-label status-label-featured">{{t 'featured'}}</span>
{{/if}}
{{#is status 'none'}}
{{else}}
<span class="status-label-{{status_dasherized}} status-label striped-list-status">{{status_name}}</span>
{{/is}}
</span>
<ul class="meta-group">
<li class="meta-data">{{author.name}}</li>
{{#if editor}}
<li class="meta-data">{{date edited_at timeago=true}}</li>
<li class="meta-data">{{t 'edited'}}</li>
{{else}}
<li class="meta-data">{{date created_at timeago=true}}</li>
{{/if}}
</ul>
</span>
<div class="post-overview-count striped-list-count">
<span class="striped-list-count-item">
<span class="striped-list-number">{{vote_sum}}</span>
{{t 'vote' count=vote_sum}}
</span>
<span class="striped-list-count-item">
<span class="striped-list-number">{{comment_count}}</span>
{{t 'comment' count=comment_count}}
</span>
</div>
</div>
</li>
{{/each}}
</ul>
{{pagination}}
{{#if featured_posts}}
<section class="section community-featured-posts">
<h3>{{t 'featured_posts'}}</h3>
<ul class="promoted-articles">
{{#each featured_posts}}
<li class="promoted-articles-item">
<a href="{{url}}">
{{title}}
</a>
</li>
{{/each}}
</ul>
</section>
{{/if}}
<section class="community-activity activity">
{{#if help_center.community_enabled}}
{{recent_activity scope='community'}}
{{/if}}
</section>
<section class="container community-footer">
<h4>{{t 'suggest_new_post'}}</h4>
{{link 'new_post' role='button' class='button-large'}}
</section>
</div>