Fix theme text strings for `search_placeholder_text` and `results_found`
Close #104
This commit is contained in:
parent
ce6162faee
commit
8b9af8e812
|
@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
|
|||
- Update GitHub issue templates.
|
||||
|
||||
### Fixed
|
||||
- Fix theme text strings for `search_placeholder_text` and `results_found`. [#104](https://github.com/mmistakes/jekyll-theme-basically-basic/issues/104)
|
||||
- Remove stray `console.log` from lunr-search-scripts [#105](https://github.com/mmistakes/jekyll-theme-basically-basic/pull/105)
|
||||
- Add missing `/` in icon-gitlab.html. [#80](https://github.com/mmistakes/jekyll-theme-basically-basic/pull/80)
|
||||
|
||||
|
|
|
@ -351,6 +351,10 @@ t:
|
|||
skip_content: "Skip to content"
|
||||
skip_footer: "Skip to footer"
|
||||
menu: "Menu"
|
||||
search: "Search"
|
||||
site_search: "Site Search"
|
||||
results_found: "Result(s) found"
|
||||
search_placeholder_text: "Enter your search term..."
|
||||
home: "Home"
|
||||
newer: "Newer"
|
||||
older: "Older"
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
{%- case search_provider -%}
|
||||
{%- when "lunr" -%}
|
||||
<label class="visually-hidden" for="search">{{ site.data.theme.t.site_search | default: 'Site Search' }}</label>
|
||||
<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...' }}" />
|
||||
<input type="text" id="search" class="search-input" aria-describedby="results-count" tabindex="-1" placeholder="{{ site.data.theme.t.search_placeholder_text | default: 'Enter your search term...' }}" />
|
||||
<div id="results" class="results"></div>
|
||||
{%- when "algolia" -%}
|
||||
<div tabindex="-1" class="search-searchbar"></div>
|
||||
|
|
|
@ -35,7 +35,7 @@ search.addWidget(
|
|||
instantsearch.widgets.searchBox({
|
||||
container: '.search-searchbar',
|
||||
{% unless site.algolia.powered_by == false %}poweredBy: true,{% endunless %}
|
||||
placeholder: '{{ site.data.theme.t.menu.search_placeholder_text | default: "Enter your search term..." }}'
|
||||
placeholder: '{{ site.data.theme.t.search_placeholder_text | default: "Enter your search term..." }}'
|
||||
})
|
||||
);
|
||||
search.addWidget(
|
||||
|
|
|
@ -86,7 +86,7 @@
|
|||
})
|
||||
});
|
||||
resultdiv.empty();
|
||||
resultdiv.prepend('<p id="results-count" class="results-found">' + result.length + ' {{ site.data.theme.t.menu.results_found | default: "Result(s) found" }}</p>');
|
||||
resultdiv.prepend('<p id="results-count" class="results-found">' + result.length + ' {{ site.data.theme.t.results_found | default: "Result(s) found" }}</p>');
|
||||
for (var item in result) {
|
||||
var ref = result[item].ref;
|
||||
var searchitem =
|
||||
|
|
Loading…
Reference in New Issue