mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-11-28 01:10:58 +01:00
Fixed search in German, French and other languages
This commit is contained in:
parent
1df750a9fe
commit
36e1e3db8b
2
material/assets/javascripts/bundle.594f2bf6.min.js
vendored
Normal file
2
material/assets/javascripts/bundle.594f2bf6.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
1
material/assets/javascripts/bundle.594f2bf6.min.js.map
Normal file
1
material/assets/javascripts/bundle.594f2bf6.min.js.map
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,10 +1,10 @@
|
|||||||
{
|
{
|
||||||
"assets/javascripts/bundle.js": "assets/javascripts/bundle.ff925e8b.min.js",
|
"assets/javascripts/bundle.js": "assets/javascripts/bundle.594f2bf6.min.js",
|
||||||
"assets/javascripts/bundle.js.map": "assets/javascripts/bundle.ff925e8b.min.js.map",
|
"assets/javascripts/bundle.js.map": "assets/javascripts/bundle.594f2bf6.min.js.map",
|
||||||
"assets/javascripts/vendor.js": "assets/javascripts/vendor.de50e36d.min.js",
|
"assets/javascripts/vendor.js": "assets/javascripts/vendor.de50e36d.min.js",
|
||||||
"assets/javascripts/vendor.js.map": "assets/javascripts/vendor.de50e36d.min.js.map",
|
"assets/javascripts/vendor.js.map": "assets/javascripts/vendor.de50e36d.min.js.map",
|
||||||
"assets/javascripts/worker/search.js": "assets/javascripts/worker/search.27c6a5e6.min.js",
|
"assets/javascripts/worker/search.js": "assets/javascripts/worker/search.c03f0417.min.js",
|
||||||
"assets/javascripts/worker/search.js.map": "assets/javascripts/worker/search.27c6a5e6.min.js.map",
|
"assets/javascripts/worker/search.js.map": "assets/javascripts/worker/search.c03f0417.min.js.map",
|
||||||
"assets/stylesheets/main.css": "assets/stylesheets/main.b8fb47b5.min.css",
|
"assets/stylesheets/main.css": "assets/stylesheets/main.b8fb47b5.min.css",
|
||||||
"assets/stylesheets/main.css.map": "assets/stylesheets/main.b8fb47b5.min.css.map",
|
"assets/stylesheets/main.css.map": "assets/stylesheets/main.b8fb47b5.min.css.map",
|
||||||
"assets/stylesheets/palette.css": "assets/stylesheets/palette.36d1b78f.min.css",
|
"assets/stylesheets/palette.css": "assets/stylesheets/palette.36d1b78f.min.css",
|
||||||
|
@ -180,7 +180,7 @@
|
|||||||
</div>
|
</div>
|
||||||
{% block scripts %}
|
{% block scripts %}
|
||||||
<script src="{{ 'assets/javascripts/vendor.de50e36d.min.js' | url }}"></script>
|
<script src="{{ 'assets/javascripts/vendor.de50e36d.min.js' | url }}"></script>
|
||||||
<script src="{{ 'assets/javascripts/bundle.ff925e8b.min.js' | url }}"></script>
|
<script src="{{ 'assets/javascripts/bundle.594f2bf6.min.js' | url }}"></script>
|
||||||
{%- set translations = {} -%}
|
{%- set translations = {} -%}
|
||||||
{%- for key in [
|
{%- for key in [
|
||||||
"clipboard.copy",
|
"clipboard.copy",
|
||||||
@ -204,7 +204,7 @@
|
|||||||
base: "{{ base_url }}",
|
base: "{{ base_url }}",
|
||||||
features: {{ config.theme.features | tojson }},
|
features: {{ config.theme.features | tojson }},
|
||||||
search: Object.assign({
|
search: Object.assign({
|
||||||
worker: "{{ 'assets/javascripts/worker/search.27c6a5e6.min.js' | url }}"
|
worker: "{{ 'assets/javascripts/worker/search.c03f0417.min.js' | url }}"
|
||||||
}, typeof search !== "undefined" && search)
|
}, typeof search !== "undefined" && search)
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
@ -11,7 +11,8 @@
|
|||||||
"footer.next": "التالية",
|
"footer.next": "التالية",
|
||||||
"meta.comments": "التعليقات",
|
"meta.comments": "التعليقات",
|
||||||
"meta.source": "المصدر",
|
"meta.source": "المصدر",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ar",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "بحث",
|
"search.placeholder": "بحث",
|
||||||
"search.result.placeholder": "اكتب لبدء البحث",
|
"search.result.placeholder": "اكتب لبدء البحث",
|
||||||
"search.result.none": "لا توجد نتائج",
|
"search.result.none": "لا توجد نتائج",
|
||||||
|
@ -10,7 +10,6 @@
|
|||||||
"footer.next": "Προηγούμενη",
|
"footer.next": "Προηγούμενη",
|
||||||
"meta.comments": "Σχόλια",
|
"meta.comments": "Σχόλια",
|
||||||
"meta.source": "Πηγή",
|
"meta.source": "Πηγή",
|
||||||
"search.config.pipeline": "",
|
|
||||||
"search.placeholder": "Αναζήτηση",
|
"search.placeholder": "Αναζήτηση",
|
||||||
"search.result.placeholder": "Πληκτρολογήστε για να αρχίσει η αναζήτηση",
|
"search.result.placeholder": "Πληκτρολογήστε για να αρχίσει η αναζήτηση",
|
||||||
"search.result.none": "Δε βρέθηκαν αντίστοιχα αρχεία",
|
"search.result.none": "Δε βρέθηκαν αντίστοιχα αρχεία",
|
||||||
|
@ -11,7 +11,8 @@
|
|||||||
"footer.next": "הַבָּא",
|
"footer.next": "הַבָּא",
|
||||||
"meta.comments": "הערות",
|
"meta.comments": "הערות",
|
||||||
"meta.source": "מָקוֹר",
|
"meta.source": "מָקוֹר",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ar",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "לחפש",
|
"search.placeholder": "לחפש",
|
||||||
"search.result.placeholder": "הקלד כדי להתחיל לחפש",
|
"search.result.placeholder": "הקלד כדי להתחיל לחפש",
|
||||||
"search.result.none": "אין מסמכים תואמים",
|
"search.result.none": "אין מסמכים תואמים",
|
||||||
|
@ -10,7 +10,8 @@
|
|||||||
"footer.next": "आगामी",
|
"footer.next": "आगामी",
|
||||||
"meta.comments": "टिप्पणियाँ",
|
"meta.comments": "टिप्पणियाँ",
|
||||||
"meta.source": "स्रोत",
|
"meta.source": "स्रोत",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ar"
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "खोज",
|
"search.placeholder": "खोज",
|
||||||
"search.result.placeholder": "खोज शुरू करने के लिए टाइप करें",
|
"search.result.placeholder": "खोज शुरू करने के लिए टाइप करें",
|
||||||
"search.result.none": "कोई मिलान डॉक्यूमेंट नहीं",
|
"search.result.none": "कोई मिलान डॉक्यूमेंट नहीं",
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
"meta.comments": "댓글",
|
"meta.comments": "댓글",
|
||||||
"meta.source": "출처",
|
"meta.source": "출처",
|
||||||
"search.config.lang": "ja",
|
"search.config.lang": "ja",
|
||||||
|
"search.config.pipeline": "",
|
||||||
"search.placeholder": "검색",
|
"search.placeholder": "검색",
|
||||||
"search.result.placeholder": "검색어를 입력하세요",
|
"search.result.placeholder": "검색어를 입력하세요",
|
||||||
"search.result.none": "검색어와 일치하는 문서가 없습니다",
|
"search.result.none": "검색어와 일치하는 문서가 없습니다",
|
||||||
|
@ -13,6 +13,8 @@
|
|||||||
"meta.comments": "မှတ်ချက်များ",
|
"meta.comments": "မှတ်ချက်များ",
|
||||||
"meta.source": "ရင်းမြစ်",
|
"meta.source": "ရင်းမြစ်",
|
||||||
"nav.title": "လမ်းညွှန်",
|
"nav.title": "လမ်းညွှန်",
|
||||||
|
"search.config.lang": "ar",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "ရှာရန်",
|
"search.placeholder": "ရှာရန်",
|
||||||
"search.reset": "ရှင်းလင်း",
|
"search.reset": "ရှင်းလင်း",
|
||||||
"search.result.placeholder": "ရှာဖွေခြင်းစရန် စာရိုက်ပါ",
|
"search.result.placeholder": "ရှာဖွေခြင်းစရန် စာရိုက်ပါ",
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
"meta.comments": "Комментарии",
|
"meta.comments": "Комментарии",
|
||||||
"meta.source": "Исходный код",
|
"meta.source": "Исходный код",
|
||||||
"search.config.lang": "ru",
|
"search.config.lang": "ru",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "Поиск",
|
"search.placeholder": "Поиск",
|
||||||
"search.result.placeholder": "Начните печатать для поиска",
|
"search.result.placeholder": "Начните печатать для поиска",
|
||||||
"search.result.none": "Совпадений не найдено",
|
"search.result.none": "Совпадений не найдено",
|
||||||
|
@ -10,7 +10,8 @@
|
|||||||
"footer.next": "Следеће",
|
"footer.next": "Следеће",
|
||||||
"meta.comments": "Коментари",
|
"meta.comments": "Коментари",
|
||||||
"meta.source": "Извор",
|
"meta.source": "Извор",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ru",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "Претрага",
|
"search.placeholder": "Претрага",
|
||||||
"search.result.placeholder": "Унесите појам претраге",
|
"search.result.placeholder": "Унесите појам претраге",
|
||||||
"search.result.none": "Нису пронађени документи",
|
"search.result.none": "Нису пронађени документи",
|
||||||
|
@ -138,11 +138,6 @@ export class Search {
|
|||||||
this.index = lunr(function() {
|
this.index = lunr(function() {
|
||||||
pipeline = pipeline || ["trimmer", "stopWordFilter"]
|
pipeline = pipeline || ["trimmer", "stopWordFilter"]
|
||||||
|
|
||||||
/* Set up pipeline according to configuration */
|
|
||||||
this.pipeline.reset()
|
|
||||||
for (const fn of pipeline)
|
|
||||||
this.pipeline.add(lunr[fn])
|
|
||||||
|
|
||||||
/* Set up alternate search languages */
|
/* Set up alternate search languages */
|
||||||
if (config.lang.length === 1 && config.lang[0] !== "en") {
|
if (config.lang.length === 1 && config.lang[0] !== "en") {
|
||||||
this.use((lunr as any)[config.lang[0]])
|
this.use((lunr as any)[config.lang[0]])
|
||||||
@ -150,6 +145,16 @@ export class Search {
|
|||||||
this.use((lunr as any).multiLanguage(...config.lang))
|
this.use((lunr as any).multiLanguage(...config.lang))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Set up pipeline according to configuration */
|
||||||
|
this.pipeline.reset()
|
||||||
|
for (const fn of pipeline)
|
||||||
|
this.pipeline.add(lunr[fn])
|
||||||
|
|
||||||
|
/* Set up search pipeline according to configuration */
|
||||||
|
this.searchPipeline.reset()
|
||||||
|
for (const fn of pipeline)
|
||||||
|
this.searchPipeline.add(lunr[fn])
|
||||||
|
|
||||||
/* Set up fields and reference */
|
/* Set up fields and reference */
|
||||||
this.field("title", { boost: 1000 })
|
this.field("title", { boost: 1000 })
|
||||||
this.field("text")
|
this.field("text")
|
||||||
|
@ -31,7 +31,8 @@
|
|||||||
"footer.next": "التالية",
|
"footer.next": "التالية",
|
||||||
"meta.comments": "التعليقات",
|
"meta.comments": "التعليقات",
|
||||||
"meta.source": "المصدر",
|
"meta.source": "المصدر",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ar",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "بحث",
|
"search.placeholder": "بحث",
|
||||||
"search.result.placeholder": "اكتب لبدء البحث",
|
"search.result.placeholder": "اكتب لبدء البحث",
|
||||||
"search.result.none": "لا توجد نتائج",
|
"search.result.none": "لا توجد نتائج",
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
"footer.next": "Προηγούμενη",
|
"footer.next": "Προηγούμενη",
|
||||||
"meta.comments": "Σχόλια",
|
"meta.comments": "Σχόλια",
|
||||||
"meta.source": "Πηγή",
|
"meta.source": "Πηγή",
|
||||||
"search.config.pipeline": "",
|
|
||||||
"search.placeholder": "Αναζήτηση",
|
"search.placeholder": "Αναζήτηση",
|
||||||
"search.result.placeholder": "Πληκτρολογήστε για να αρχίσει η αναζήτηση",
|
"search.result.placeholder": "Πληκτρολογήστε για να αρχίσει η αναζήτηση",
|
||||||
"search.result.none": "Δε βρέθηκαν αντίστοιχα αρχεία",
|
"search.result.none": "Δε βρέθηκαν αντίστοιχα αρχεία",
|
||||||
|
@ -31,7 +31,8 @@
|
|||||||
"footer.next": "הַבָּא",
|
"footer.next": "הַבָּא",
|
||||||
"meta.comments": "הערות",
|
"meta.comments": "הערות",
|
||||||
"meta.source": "מָקוֹר",
|
"meta.source": "מָקוֹר",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ar",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "לחפש",
|
"search.placeholder": "לחפש",
|
||||||
"search.result.placeholder": "הקלד כדי להתחיל לחפש",
|
"search.result.placeholder": "הקלד כדי להתחיל לחפש",
|
||||||
"search.result.none": "אין מסמכים תואמים",
|
"search.result.none": "אין מסמכים תואמים",
|
||||||
|
@ -30,7 +30,8 @@
|
|||||||
"footer.next": "आगामी",
|
"footer.next": "आगामी",
|
||||||
"meta.comments": "टिप्पणियाँ",
|
"meta.comments": "टिप्पणियाँ",
|
||||||
"meta.source": "स्रोत",
|
"meta.source": "स्रोत",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ar"
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "खोज",
|
"search.placeholder": "खोज",
|
||||||
"search.result.placeholder": "खोज शुरू करने के लिए टाइप करें",
|
"search.result.placeholder": "खोज शुरू करने के लिए टाइप करें",
|
||||||
"search.result.none": "कोई मिलान डॉक्यूमेंट नहीं",
|
"search.result.none": "कोई मिलान डॉक्यूमेंट नहीं",
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
"meta.comments": "댓글",
|
"meta.comments": "댓글",
|
||||||
"meta.source": "출처",
|
"meta.source": "출처",
|
||||||
"search.config.lang": "ja",
|
"search.config.lang": "ja",
|
||||||
|
"search.config.pipeline": "",
|
||||||
"search.placeholder": "검색",
|
"search.placeholder": "검색",
|
||||||
"search.result.placeholder": "검색어를 입력하세요",
|
"search.result.placeholder": "검색어를 입력하세요",
|
||||||
"search.result.none": "검색어와 일치하는 문서가 없습니다",
|
"search.result.none": "검색어와 일치하는 문서가 없습니다",
|
||||||
|
@ -33,6 +33,8 @@
|
|||||||
"meta.comments": "မှတ်ချက်များ",
|
"meta.comments": "မှတ်ချက်များ",
|
||||||
"meta.source": "ရင်းမြစ်",
|
"meta.source": "ရင်းမြစ်",
|
||||||
"nav.title": "လမ်းညွှန်",
|
"nav.title": "လမ်းညွှန်",
|
||||||
|
"search.config.lang": "ar",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "ရှာရန်",
|
"search.placeholder": "ရှာရန်",
|
||||||
"search.reset": "ရှင်းလင်း",
|
"search.reset": "ရှင်းလင်း",
|
||||||
"search.result.placeholder": "ရှာဖွေခြင်းစရန် စာရိုက်ပါ",
|
"search.result.placeholder": "ရှာဖွေခြင်းစရန် စာရိုက်ပါ",
|
||||||
|
@ -31,6 +31,7 @@
|
|||||||
"meta.comments": "Комментарии",
|
"meta.comments": "Комментарии",
|
||||||
"meta.source": "Исходный код",
|
"meta.source": "Исходный код",
|
||||||
"search.config.lang": "ru",
|
"search.config.lang": "ru",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "Поиск",
|
"search.placeholder": "Поиск",
|
||||||
"search.result.placeholder": "Начните печатать для поиска",
|
"search.result.placeholder": "Начните печатать для поиска",
|
||||||
"search.result.none": "Совпадений не найдено",
|
"search.result.none": "Совпадений не найдено",
|
||||||
|
@ -30,7 +30,8 @@
|
|||||||
"footer.next": "Следеће",
|
"footer.next": "Следеће",
|
||||||
"meta.comments": "Коментари",
|
"meta.comments": "Коментари",
|
||||||
"meta.source": "Извор",
|
"meta.source": "Извор",
|
||||||
"search.config.pipeline": "",
|
"search.config.lang": "ru",
|
||||||
|
"search.config.pipeline": "stemmer",
|
||||||
"search.placeholder": "Претрага",
|
"search.placeholder": "Претрага",
|
||||||
"search.result.placeholder": "Унесите појам претраге",
|
"search.result.placeholder": "Унесите појам претраге",
|
||||||
"search.result.none": "Нису пронађени документи",
|
"search.result.none": "Нису пронађени документи",
|
||||||
|
Loading…
Reference in New Issue
Block a user