-
-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add search placeholder by calc pages and tags
ex. Search among X titles and Y tags. Removes param searchBoxPlaceholder
- Loading branch information
1 parent
435a642
commit 030461a
Showing
2 changed files
with
16 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,10 @@ | ||
<div class="searchBox"> | ||
<input id="search" autofocus type="search" placeholder='{{ site.Params.searchBoxPlaceholder | default "Search ..." }}' autocomplete="off" /> | ||
<input id="search" autofocus type="search" placeholder=' | ||
{{- with site.Params.headers }} | ||
{{- print "Search among" }} | ||
{{- printf " %d %s " (len site.RegularPages) (.key | pluralize | lower) }} | ||
{{- print "and" }} | ||
{{- printf " %d %s..." (len site.Taxonomies.tags) (.value | pluralize | lower) }} | ||
{{- end -}} | ||
' autocomplete="off" /> | ||
</div> |