forked from BitcoinDesign/Guide
-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.html
35 lines (28 loc) · 950 Bytes
/
search.html
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
---
title: Search
description: Search the Bitcoin Design Guide
layout: search
image: /assets/images/search-preview.jpg
---
<form action="/search.html" msethod="get">
<input type="text" id="search-page-input" name="query">
</form>
<ul id="search-page-results"></ul>
<script>
window.store = {
{%- assign content_pages = site.html_pages -%}
{%- assign content = site.posts | concat: content_pages -%}
{% for page in content %}
"{{ page.url | slugify }}": {
"title": "{{ page.title | xml_escape }}",
"author": "{{ page.author | xml_escape }}",
"category": "{{ page.category | xml_escape }}",
"content": {{ page.content | markdownify | strip_html | strip_newlines | jsonify }},
"url": "{{ page.url | xml_escape }}"
}
{% unless forloop.last %},{% endunless %}
{% endfor %}
};
</script>
<script src="/js/lunr.min.js"></script>
<script src="/js/search-page.js"></script>