Skip to content

Commit 6517902

Browse files
authored
Merge pull request #670 from zendesk/malgorzata/kiaw-1464-fix-reading-order
style: change order of the filters title with toggle button
2 parents 2818732 + 5bab8cc commit 6517902

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

templates/search_results.hbs

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
<div class="search-results">
1515
<aside class="search-results-sidebar">
1616
{{#if source_filters}}
17+
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_source'}}</h3>
1718
<section class="filters-in-section collapsible-sidebar">
1819
<button type="button" class="collapsible-sidebar-toggle" aria-expanded="false" aria-label="{{t 'search_result_source_menu'}}">
1920
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" focusable="false" viewBox="0 0 12 12" aria-hidden="true" class="collapsible-sidebar-toggle-icon chevron-icon">
@@ -23,7 +24,6 @@
2324
<path stroke="currentColor" stroke-linecap="round" d="M3 9l6-6m0 6L3 3"/>
2425
</svg>
2526
</button>
26-
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_source'}}</h3>
2727
<ul class="multibrand-filter-list multibrand-filter-list--collapsed">
2828
{{#each source_filters}}
2929
<li>
@@ -43,6 +43,7 @@
4343
{{/if}}
4444
{{#if type_filters}}
4545
<section class="filters-in-section collapsible-sidebar">
46+
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_type'}}</h3>
4647
<button type="button" class="collapsible-sidebar-toggle" aria-expanded="false" aria-label="{{t 'search_result_type_menu'}}">
4748
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" focusable="false" viewBox="0 0 12 12" aria-hidden="true" class="collapsible-sidebar-toggle-icon chevron-icon">
4849
<path fill="none" stroke="currentColor" stroke-linecap="round" d="M3 4.5l2.6 2.6c.2.2.5.2.7 0L9 4.5"/>
@@ -51,7 +52,6 @@
5152
<path stroke="currentColor" stroke-linecap="round" d="M3 9l6-6m0 6L3 3"/>
5253
</svg>
5354
</button>
54-
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_type'}}</h3>
5555
<ul class="multibrand-filter-list multibrand-filter-list--collapsed">
5656
{{#each type_filters}}
5757
<li>
@@ -70,6 +70,12 @@
7070
{{/if}}
7171
{{#if subfilters}}
7272
<section class="filters-in-section collapsible-sidebar">
73+
{{#is current_filter.identifier 'knowledge_base'}}
74+
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_by_category'}}</h3>
75+
{{/is}}
76+
{{#is current_filter.identifier 'community'}}
77+
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_by_topic'}}</h3>
78+
{{/is}}
7379
<button type="button" class="collapsible-sidebar-toggle" aria-expanded="false" aria-label="{{t 'search_result_subfilter_menu'}}">
7480
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" focusable="false" viewBox="0 0 12 12" aria-hidden="true" class="collapsible-sidebar-toggle-icon chevron-icon">
7581
<path fill="none" stroke="currentColor" stroke-linecap="round" d="M3 4.5l2.6 2.6c.2.2.5.2.7 0L9 4.5"/>
@@ -78,12 +84,6 @@
7884
<path stroke="currentColor" stroke-linecap="round" d="M3 9l6-6m0 6L3 3"/>
7985
</svg>
8086
</button>
81-
{{#is current_filter.identifier 'knowledge_base'}}
82-
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_by_category'}}</h3>
83-
{{/is}}
84-
{{#is current_filter.identifier 'community'}}
85-
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_by_topic'}}</h3>
86-
{{/is}}
8787
<ul class="multibrand-filter-list multibrand-filter-list--collapsed">
8888
{{#each subfilters}}
8989
<li>
@@ -108,6 +108,7 @@
108108
{{/if}}
109109
{{#if content_tag_filters}}
110110
<section class="filters-in-section collapsible-sidebar">
111+
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_content_tag'}}</h3>
111112
<button type="button" class="collapsible-sidebar-toggle" aria-expanded="false">
112113
<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" focusable="false" viewBox="0 0 12 12" aria-hidden="true" class="collapsible-sidebar-toggle-icon chevron-icon">
113114
<path fill="none" stroke="currentColor" stroke-linecap="round" d="M3 4.5l2.6 2.6c.2.2.5.2.7 0L9 4.5"/>
@@ -116,7 +117,6 @@
116117
<path stroke="currentColor" stroke-linecap="round" d="M3 9l6-6m0 6L3 3"/>
117118
</svg>
118119
</button>
119-
<h3 class="collapsible-sidebar-title sidenav-title">{{t 'filter_content_tag'}}</h3>
120120
<ul class="multibrand-filter-list multibrand-filter-list--collapsed">
121121
{{#each content_tag_filters}}
122122
{{#if selected}}

0 commit comments

Comments
 (0)