File tree Expand file tree Collapse file tree 4 files changed +9
-2
lines changed Expand file tree Collapse file tree 4 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
5
5
The format is based on [ Keep a Changelog] ( http://keepachangelog.com/ )
6
6
and this project adheres to [ Semantic Versioning] ( http://semver.org/ ) .
7
7
8
+ ## Unreleased
9
+
10
+ ### Added
11
+ - Accessibility enhancements for Lunr search form.
12
+
8
13
## [ 1.3.1] - 2018-02-16
9
14
10
15
### Changed
Original file line number Diff line number Diff line change 9
9
skip_footer : " Skip to footer"
10
10
menu : " Menu"
11
11
search : " Search"
12
+ site_search : " Site Search"
12
13
results_found : " Result(s) found"
13
14
search_placeholder_text : " Enter your search term..."
14
15
home : " Home"
Original file line number Diff line number Diff line change 3
3
{%- assign search_provider = site.search_provider | default: "lunr" -%}
4
4
{%- case search_provider -%}
5
5
{%- when "lunr" -%}
6
- < input type ="text " id ="search " class ="search-input " tabindex ="-1 " placeholder ="{{ site.data.theme.t.menu.search_placeholder_text | default: 'Enter your search term...' }} " />
6
+ < label class ="visually-hidden " for ="search "> {{ site.data.theme.t.site_search | default: 'Site Search' }}</ label >
7
+ < input type ="text " id ="search " class ="search-input " aria-describedby ="results-count " tabindex ="-1 " placeholder ="{{ site.data.theme.t.menu.search_placeholder_text | default: 'Enter your search term...' }} " />
7
8
< div id ="results " class ="results "> </ div >
8
9
{%- when "algolia" -%}
9
10
< div tabindex ="-1 " class ="search-searchbar "> </ div >
Original file line number Diff line number Diff line change 88
88
} )
89
89
} ) ;
90
90
resultdiv . empty ( ) ;
91
- resultdiv . prepend ( '<p class="results-found">' + result . length + ' {{ site.data.theme.t.menu.results_found | default: "Result(s) found" }}</p>' ) ;
91
+ resultdiv . prepend ( '<p id="results-count" class="results-found">' + result . length + ' {{ site.data.theme.t.menu.results_found | default: "Result(s) found" }}</p>' ) ;
92
92
for ( var item in result ) {
93
93
var ref = result [ item ] . ref ;
94
94
var searchitem =
You can’t perform that action at this time.
0 commit comments