mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2024-06-14 11:52:32 +03:00
Fixed search transform removing numbers from query
This commit is contained in:
parent
792494f4cf
commit
a3c03aefb9
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
||||
{
|
||||
"assets/javascripts/bundle.js": "assets/javascripts/bundle.dd72b84b.min.js",
|
||||
"assets/javascripts/bundle.js.map": "assets/javascripts/bundle.dd72b84b.min.js.map",
|
||||
"assets/javascripts/bundle.js": "assets/javascripts/bundle.38f5c9b5.min.js",
|
||||
"assets/javascripts/bundle.js.map": "assets/javascripts/bundle.38f5c9b5.min.js.map",
|
||||
"assets/javascripts/vendor.js": "assets/javascripts/vendor.de50e36d.min.js",
|
||||
"assets/javascripts/vendor.js.map": "assets/javascripts/vendor.de50e36d.min.js.map",
|
||||
"assets/javascripts/worker/search.js": "assets/javascripts/worker/search.9b3611bd.min.js",
|
||||
|
@ -183,7 +183,7 @@
|
||||
</div>
|
||||
{% block scripts %}
|
||||
<script src="{{ 'assets/javascripts/vendor.de50e36d.min.js' | url }}"></script>
|
||||
<script src="{{ 'assets/javascripts/bundle.dd72b84b.min.js' | url }}"></script>
|
||||
<script src="{{ 'assets/javascripts/bundle.38f5c9b5.min.js' | url }}"></script>
|
||||
{%- set translations = {} -%}
|
||||
{%- for key in [
|
||||
"clipboard.copy",
|
||||
|
@ -49,7 +49,7 @@ export type SearchTransformFn = (value: string) => string
|
||||
*/
|
||||
export function defaultTransform(value: string): string {
|
||||
return value
|
||||
.replace(/(?:^|\s+)[*+-:^~]+(?=\s+|$)/g, "")
|
||||
.replace(/(?:^|\s+)[*+\-:^~]+(?=\s+|$)/g, "")
|
||||
.trim()
|
||||
.replace(/\s+|(?![^\x00-\x7F]|^)$|\b$/g, "* ")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user